Skip to content

Commit 40ba673

Browse files
committed
[PSR-2 Compliance] The Great @codingStandardsIgnoreFile Massacre
- apply manual fixes to make PHPCS happy, mainly "Line exceeds maximum limit of 120 characters" violations
1 parent d813974 commit 40ba673

File tree

249 files changed

+1621
-746
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

249 files changed

+1621
-746
lines changed

app/code/Magento/AdminNotification/Block/Grid/Renderer/Actions.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,8 @@ public function __construct(
3737
*/
3838
public function render(\Magento\Framework\DataObject $row)
3939
{
40-
$readDetailsHtml = $row->getUrl() ? '<a class="action-details" target="_blank" href="' . $row->getUrl() . '">' . __(
41-
'Read Details'
42-
) . '</a>' : '';
40+
$readDetailsHtml = $row->getUrl() ? '<a class="action-details" target="_blank" href="' . $row->getUrl() . '">'
41+
. __('Read Details') . '</a>' : '';
4342

4443
$markAsReadHtml = !$row->getIsRead() ? '<a class="action-mark" href="' . $this->getUrl(
4544
'*/*/markAsRead/',

app/code/Magento/AdminNotification/Model/ResourceModel/Grid/Collection.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,14 @@
1111
*/
1212
namespace Magento\AdminNotification\Model\ResourceModel\Grid;
1313

14+
use Magento\Framework\Model\ResourceModel\Db\Collection\AbstractCollection;
15+
1416
class Collection extends \Magento\AdminNotification\Model\ResourceModel\Inbox\Collection
1517
{
1618
/**
1719
* Add remove filter
1820
*
19-
* @return \Magento\AdminNotification\Model\ResourceModel\Grid\Collection|\Magento\Framework\Model\ResourceModel\Db\Collection\AbstractCollection
21+
* @return \Magento\AdminNotification\Model\ResourceModel\Grid\Collection|AbstractCollection
2022
*/
2123
protected function _initSelect()
2224
{

app/code/Magento/AdvancedPricingImportExport/Model/Import/AdvancedPricing.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,8 @@ class AdvancedPricing extends \Magento\ImportExport\Model\Import\Entity\Abstract
6767
ValidatorInterface::ERROR_INVALID_TIER_PRICE_TYPE => 'Value for \'tier_price_value_type\' ' .
6868
'attribute contains incorrect value, acceptable values are Fixed, Discount',
6969
ValidatorInterface::ERROR_TIER_DATA_INCOMPLETE => 'Tier Price data is incomplete',
70-
ValidatorInterface::ERROR_INVALID_ATTRIBUTE_DECIMAL => 'Value for \'%s\' attribute contains incorrect value, acceptable values are in decimal format',
70+
ValidatorInterface::ERROR_INVALID_ATTRIBUTE_DECIMAL
71+
=> 'Value for \'%s\' attribute contains incorrect value, acceptable values are in decimal format',
7172
];
7273

7374
/**

app/code/Magento/AdvancedPricingImportExport/Model/Import/AdvancedPricing/Validator/Website.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ public function isValid($value)
8585
*/
8686
public function getAllWebsitesValue()
8787
{
88-
return AdvancedPricing::VALUE_ALL_WEBSITES . ' [' . $this->websiteModel->getBaseCurrency()->getCurrencyCode() . ']';
88+
return AdvancedPricing::VALUE_ALL_WEBSITES
89+
. ' [' . $this->websiteModel->getBaseCurrency()->getCurrencyCode() . ']';
8990
}
9091
}

app/code/Magento/Authorization/Model/ResourceModel/Rules.php

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,10 @@ public function saveRel(\Magento\Authorization\Model\Rules $rule)
9999

100100
// If all was selected save it only and nothing else.
101101
if ($postedResources === [$this->_rootResource->getId()]) {
102-
$insertData = $this->_prepareDataForTable(new \Magento\Framework\DataObject($row), $this->getMainTable());
102+
$insertData = $this->_prepareDataForTable(
103+
new \Magento\Framework\DataObject($row),
104+
$this->getMainTable()
105+
);
103106

104107
$connection->insert($this->getMainTable(), $insertData);
105108
} else {
@@ -111,7 +114,10 @@ public function saveRel(\Magento\Authorization\Model\Rules $rule)
111114
$row['permission'] = in_array($resourceId, $postedResources) ? 'allow' : 'deny';
112115
$row['resource_id'] = $resourceId;
113116

114-
$insertData = $this->_prepareDataForTable(new \Magento\Framework\DataObject($row), $this->getMainTable());
117+
$insertData = $this->_prepareDataForTable(
118+
new \Magento\Framework\DataObject($row),
119+
$this->getMainTable()
120+
);
115121
$connection->insert($this->getMainTable(), $insertData);
116122
}
117123
}

app/code/Magento/Backend/Block/Dashboard/AbstractDashboard.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66

77
namespace Magento\Backend\Block\Dashboard;
88

9+
use Magento\Framework\Model\ResourceModel\Db\Collection\AbstractCollection;
10+
911
/**
1012
* Adminhtml dashboard tab abstract
1113
*
@@ -38,7 +40,7 @@ public function __construct(
3840
}
3941

4042
/**
41-
* @return array|\Magento\Framework\Model\ResourceModel\Db\Collection\AbstractCollection|\Magento\Eav\Model\Entity\Collection\Abstract
43+
* @return array|AbstractCollection|\Magento\Eav\Model\Entity\Collection\Abstract
4244
*/
4345
public function getCollection()
4446
{

app/code/Magento/Backend/Block/Menu.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,9 @@ protected function _getAnchorLabel($menuItem)
132132
*/
133133
protected function _renderMouseEvent($menuItem)
134134
{
135-
return $menuItem->hasChildren() ? 'onmouseover="Element.addClassName(this,\'over\')" onmouseout="Element.removeClassName(this,\'over\')"' : '';
135+
return $menuItem->hasChildren()
136+
? 'onmouseover="Element.addClassName(this,\'over\')" onmouseout="Element.removeClassName(this,\'over\')"'
137+
: '';
136138
}
137139

138140
/**

app/code/Magento/Backend/Block/Page/Header.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66

77
namespace Magento\Backend\Block\Page;
88

9+
use Magento\Store\Model\ScopeInterface;
10+
911
/**
1012
* Adminhtml header block
1113
*
@@ -78,6 +80,6 @@ public function getLogoutLink()
7880
*/
7981
public function displayNoscriptNotice()
8082
{
81-
return $this->_scopeConfig->getValue('web/browser_capabilities/javascript', \Magento\Store\Model\ScopeInterface::SCOPE_STORE);
83+
return $this->_scopeConfig->getValue('web/browser_capabilities/javascript', ScopeInterface::SCOPE_STORE);
8284
}
8385
}

app/code/Magento/Backend/Block/Page/Notices.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@
1111
*/
1212
namespace Magento\Backend\Block\Page;
1313

14+
use Magento\Store\Model\ScopeInterface;
15+
1416
class Notices extends \Magento\Backend\Block\Template
1517
{
1618
/**
@@ -20,7 +22,7 @@ class Notices extends \Magento\Backend\Block\Template
2022
*/
2123
public function displayNoscriptNotice()
2224
{
23-
return $this->_scopeConfig->getValue('web/browser_capabilities/javascript', \Magento\Store\Model\ScopeInterface::SCOPE_STORE);
25+
return $this->_scopeConfig->getValue('web/browser_capabilities/javascript', ScopeInterface::SCOPE_STORE);
2426
}
2527

2628
/**
@@ -30,6 +32,6 @@ public function displayNoscriptNotice()
3032
*/
3133
public function displayDemoNotice()
3234
{
33-
return $this->_scopeConfig->getValue('design/head/demonotice', \Magento\Store\Model\ScopeInterface::SCOPE_STORE);
35+
return $this->_scopeConfig->getValue('design/head/demonotice', ScopeInterface::SCOPE_STORE);
3436
}
3537
}

app/code/Magento/Backend/Block/Store/Switcher/Form/Renderer/Fieldset.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,12 @@
66

77
namespace Magento\Backend\Block\Store\Switcher\Form\Renderer;
88

9+
use Magento\Framework\Data\Form\Element\Renderer\RendererInterface;
10+
911
/**
1012
* Form fieldset renderer
1113
*/
12-
class Fieldset extends \Magento\Backend\Block\Template implements \Magento\Framework\Data\Form\Element\Renderer\RendererInterface
14+
class Fieldset extends \Magento\Backend\Block\Template implements RendererInterface
1315
{
1416
/**
1517
* Form element which re-rendering

0 commit comments

Comments
 (0)