Skip to content

Commit b676d40

Browse files
committed
Code style fixes
1 parent f6f7f37 commit b676d40

24 files changed

+35
-44
lines changed

Block/Adminhtml/Category.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,5 +45,4 @@ protected function _prepareLayout()
4545
}
4646
return parent::_prepareLayout();
4747
}
48-
4948
}

Block/Adminhtml/Category/CreateButton.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
/**
1212
* Class CreateButton
1313
*/
14-
class CreateButton extends \Magefan\Community\Block\Adminhtml\Edit\CreateButton
14+
class CreateButton extends \Magefan\Community\Block\Adminhtml\Edit\CreateButton
1515
{
1616
/**
1717
* @return array|string

Block/Adminhtml/Category/DuplicateButton.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,4 @@ public function getButtonData()
2323
}
2424
return parent::getButtonData();
2525
}
26-
27-
2826
}

Block/Adminhtml/Category/SaveAndContinueButton.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
/**
1212
* Class SaveAndContinueButton
1313
*/
14-
class SaveAndContinueButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveAndContinueButton
14+
class SaveAndContinueButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveAndContinueButton
1515
{
1616
/**
1717
* @return array|string

Block/Adminhtml/Category/SaveButton.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
/**
1212
* Class SaveButton
1313
*/
14-
class SaveButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveButton
14+
class SaveButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveButton
1515
{
1616
/**
1717
* @return array|string

Block/Adminhtml/Comment/SaveAndContinueButton.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
/**
1212
* Class SaveAndContinueButton
1313
*/
14-
class SaveAndContinueButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveAndContinueButton
14+
class SaveAndContinueButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveAndContinueButton
1515
{
1616
/**
1717
* @return array|string

Block/Adminhtml/Comment/SaveButton.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
/**
1212
* Class SaveButton
1313
*/
14-
class SaveButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveButton
14+
class SaveButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveButton
1515
{
1616
/**
1717
* @return array|string

Block/Adminhtml/Post.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ protected function _construct()
2929
if (!$this->_authorization->isAllowed("Magefan_Blog::post_save")) {
3030
$this->removeButton('add');
3131
}
32-
3332
}
3433

3534
/**

Block/Adminhtml/Post/DuplicateButton.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,4 @@ public function getButtonData()
2323
}
2424
return parent::getButtonData();
2525
}
26-
27-
2826
}

Block/Adminhtml/Post/SaveAndContinueButton.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
/**
1212
* Class SaveAndContinueButton
1313
*/
14-
class SaveAndContinueButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveAndContinueButton
14+
class SaveAndContinueButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveAndContinueButton
1515
{
1616
/**
1717
* @return array|string

Block/Adminhtml/Tag/CreateButton.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
/**
1212
* Class CreateButton
1313
*/
14-
class CreateButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveButton
14+
class CreateButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveButton
1515
{
1616
/**
1717
* @return array|string

Block/Adminhtml/Tag/SaveAndContinueButton.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
/**
1212
* Class SaveAndContinueButton
1313
*/
14-
class SaveAndContinueButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveAndContinueButton
14+
class SaveAndContinueButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveAndContinueButton
1515
{
1616
/**
1717
* @return array|string

Block/Adminhtml/Tag/SaveButton.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
/**
1212
* Class SaveButton
1313
*/
14-
class SaveButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveButton
14+
class SaveButton extends \Magefan\Community\Block\Adminhtml\Edit\SaveButton
1515
{
1616
/**
1717
* @return array|string

Block/Category/PostList.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,11 +41,11 @@ public function getCollectionOrderField()
4141
$postsSortBy = $this->getCategory()->getData('posts_sort_by');
4242

4343
switch ($postsSortBy) {
44-
case PostsSortBy::POSITION :
44+
case PostsSortBy::POSITION:
4545
return self::POSTS_SORT_FIELD_BY_POSITION;
46-
case PostsSortBy::TITLE :
46+
case PostsSortBy::TITLE:
4747
return self::POSTS_SORT_FIELD_BY_TITLE;
48-
default :
48+
default:
4949
return parent::getCollectionOrderField();
5050
}
5151
}

Block/Index.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,11 +78,11 @@ public function getCollectionOrderField()
7878
);
7979

8080
switch ($postsSortBy) {
81-
case PostsSortBy::POSITION :
81+
case PostsSortBy::POSITION:
8282
return self::POSTS_SORT_FIELD_BY_POSITION;
83-
case PostsSortBy::TITLE :
83+
case PostsSortBy::TITLE:
8484
return self::POSTS_SORT_FIELD_BY_TITLE;
85-
default :
85+
default:
8686
return parent::getCollectionOrderField();
8787
}
8888
}

Block/Post/View/Comments.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,8 @@ public function getCommentsType()
6969
/**
7070
* @return bool
7171
*/
72-
public function displayPrivacyPolicyCheckbox() {
72+
public function displayPrivacyPolicyCheckbox()
73+
{
7374
return $this->_scopeConfig->getValue(
7475
'mfblog/post_view/comments/display_privacy_policy_checkbox',
7576
ScopeInterface::SCOPE_STORE

Block/Rss/Feed.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ public function getPostContent($post)
6565
{
6666
$content = $post->getFilteredContent();
6767
/* Remove iframes */
68-
$content = preg_replace('/<iframe.*?\/iframe>/i','', $content);
68+
$content = preg_replace('/<iframe.*?\/iframe>/i', '', $content);
6969

7070
/* Remove style tags */
7171
$content = preg_replace('/(<[^>]+) style=".*?"/i', '$1', $content);

Controller/Adminhtml/Tag/Save.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,5 +45,4 @@ protected function filterParams($data)
4545

4646
return $data;
4747
}
48-
4948
}

Model/CategoryManagement.php

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,15 @@ public function __construct(
3030
}
3131

3232
/**
33-
* Retrieve list of category by page type, term, store, etc
34-
*
35-
* @param string $type
36-
* @param string $term
37-
* @param int $storeId
38-
* @param int $page
39-
* @param int $limit
40-
* @return string
41-
*/
33+
* Retrieve list of category by page type, term, store, etc
34+
*
35+
* @param string $type
36+
* @param string $term
37+
* @param int $storeId
38+
* @param int $page
39+
* @param int $limit
40+
* @return string
41+
*/
4242
public function getList($type, $term, $storeId, $page, $limit)
4343
{
4444
try {

Model/Config.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
/**
1515
* Magefan Blog Config Model
1616
*/
17-
class Config
17+
class Config
1818
{
1919
/**
2020
* Extension enabled config path
@@ -151,11 +151,11 @@ public function getConfig($path, $storeId = null)
151151
* @param $pageType
152152
* @return bool
153153
*/
154-
public function getDisplayCanonicalTag($pageType) {
154+
public function getDisplayCanonicalTag($pageType)
155+
{
155156

156157
$displayFor = explode(',', $this->getConfig(self::XML_PATH_DISPLAY_CANONICAL_TAG_FOR));
157158

158-
return in_array($pageType, $displayFor) || in_array(self::CANONICAL_PAGE_TYPE_ALL, $displayFor) ? true : false;
159-
159+
return in_array($pageType, $displayFor) || in_array(self::CANONICAL_PAGE_TYPE_ALL, $displayFor) ? true : false;
160160
}
161161
}

Model/Config/Source/BlogPages.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
namespace Magefan\Blog\Model\Config\Source;
44

5-
65
class BlogPages implements \Magento\Framework\Option\ArrayInterface
76
{
87
/**
@@ -37,4 +36,4 @@ public function toArray()
3736
}
3837
return $array;
3938
}
40-
}
39+
}

Model/Import/Aw.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -148,8 +148,6 @@ public function execute()
148148
$tag = $existingTags[$data['title']];
149149
$oldTags[$data['old_id']] = $tag;
150150
}
151-
152-
153151
} catch (\Magento\Framework\Exception\LocalizedException $e) {
154152
$this->_skippedTags[] = $data['title'];
155153
$this->_logger->addDebug('Blog Tag Import [' . $data['title'] . ']: '. $e->getMessage());

Plugin/Magento/Sitemap/SitemapPlugin.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,6 @@ public function afterGenerateXml(\Magento\Framework\Model\AbstractModel $sitemap
9393

9494
$blogSitemap->generateXml();
9595
}
96-
9796
}
9897
return $result;
9998
}

Setup/InstallData.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,9 @@ public function __construct(
5454
public function install(ModuleDataSetupInterface $setup, ModuleContextInterface $context)
5555
{
5656
try {
57-
$this->state->setAreaCode('adminhtml');
58-
} catch (\Exception $e) {}
57+
$this->state->setAreaCode('adminhtml');
58+
} catch (\Exception $e) {
59+
}
5960

6061
$data = [
6162
'title' => 'Hello world!',

0 commit comments

Comments
 (0)