Skip to content

Commit 5d9e324

Browse files
author
Mike Weis
committed
Merge remote-tracking branch 'mainline/develop' into develop
2 parents 0dc9854 + 36d8dad commit 5d9e324

File tree

466 files changed

+6779
-2738
lines changed

Some content is hidden

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

466 files changed

+6779
-2738
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ atlassian*
2020
/lib/internal/flex/varien/.project
2121
/lib/internal/flex/varien/.settings
2222
/node_modules
23+
/.grunt
2324

2425
/pub/media/*.*
2526
!/pub/media/.htaccess

app/code/Magento/Authorization/Model/Acl/AclRetriever.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,9 @@ public function getAllowedResourcesByUser($userType, $userId)
7575
try {
7676
$role = $this->_getUserRole($userType, $userId);
7777
if (!$role) {
78-
throw new AuthorizationException('The role associated with the specified user cannot be found.');
78+
throw new AuthorizationException(
79+
__('The role associated with the specified user cannot be found.')
80+
);
7981
}
8082
$allowedResources = $this->getAllowedResourcesByRole($role->getId());
8183
} catch (AuthorizationException $e) {

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

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -89,18 +89,4 @@ public function getButtonHtml($label, $onclick, $class = '', $buttonId = null, $
8989
$dataAttr
9090
)->toHtml();
9191
}
92-
93-
/**
94-
* @return string
95-
*/
96-
public function getGlobalIcon()
97-
{
98-
return '<img src="' . $this->getViewFileUrl(
99-
'images/fam_link.gif'
100-
) . '" alt="' . __(
101-
'Global Attribute'
102-
) . '" title="' . __(
103-
'This attribute shares the same value in all stores.'
104-
) . '" class="attribute-global"/>';
105-
}
10692
}

app/code/Magento/Backend/Controller/Adminhtml/Ajax/Translate.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,19 +16,19 @@ class Translate extends \Magento\Backend\App\Action
1616
protected $inlineParser;
1717

1818
/**
19-
* @var \Magento\Framework\Controller\Result\JSONFactory
19+
* @var \Magento\Framework\Controller\Result\JsonFactory
2020
*/
2121
protected $resultJsonFactory;
2222

2323
/**
2424
* @param Action\Context $context
2525
* @param \Magento\Framework\Translate\Inline\ParserInterface $inlineParser
26-
* @param \Magento\Framework\Controller\Result\JSONFactory $resultJsonFactory
26+
* @param \Magento\Framework\Controller\Result\JsonFactory $resultJsonFactory
2727
*/
2828
public function __construct(
2929
Action\Context $context,
3030
\Magento\Framework\Translate\Inline\ParserInterface $inlineParser,
31-
\Magento\Framework\Controller\Result\JSONFactory $resultJsonFactory
31+
\Magento\Framework\Controller\Result\JsonFactory $resultJsonFactory
3232
) {
3333
parent::__construct($context);
3434
$this->resultJsonFactory = $resultJsonFactory;
@@ -38,13 +38,13 @@ public function __construct(
3838
/**
3939
* Ajax action for inline translation
4040
*
41-
* @return \Magento\Framework\Controller\Result\JSON
41+
* @return \Magento\Framework\Controller\Result\Json
4242
*/
4343
public function execute()
4444
{
4545
$translate = (array)$this->getRequest()->getPost('translate');
4646

47-
/** @var \Magento\Framework\Controller\Result\JSON $resultJson */
47+
/** @var \Magento\Framework\Controller\Result\Json $resultJson */
4848
$resultJson = $this->resultJsonFactory->create();
4949
try {
5050
$this->inlineParser->processAjaxPost($translate);

app/code/Magento/Backend/Controller/Adminhtml/Auth/DeniedJson.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,17 @@
99
class DeniedJson extends \Magento\Backend\Controller\Adminhtml\Auth
1010
{
1111
/**
12-
* @var \Magento\Framework\Controller\Result\JSONFactory
12+
* @var \Magento\Framework\Controller\Result\JsonFactory
1313
*/
1414
protected $resultJsonFactory;
1515

1616
/**
1717
* @param \Magento\Backend\App\Action\Context $context
18-
* @param \Magento\Framework\Controller\Result\JSONFactory $resultJsonFactory
18+
* @param \Magento\Framework\Controller\Result\JsonFactory $resultJsonFactory
1919
*/
2020
public function __construct(
2121
\Magento\Backend\App\Action\Context $context,
22-
\Magento\Framework\Controller\Result\JSONFactory $resultJsonFactory
22+
\Magento\Framework\Controller\Result\JsonFactory $resultJsonFactory
2323
) {
2424
parent::__construct($context);
2525
$this->resultJsonFactory = $resultJsonFactory;
@@ -41,11 +41,11 @@ protected function _getDeniedJson()
4141
/**
4242
* Denied JSON action
4343
*
44-
* @return \Magento\Framework\Controller\Result\JSON
44+
* @return \Magento\Framework\Controller\Result\Json
4545
*/
4646
public function execute()
4747
{
48-
/** @var \Magento\Framework\Controller\Result\JSON $resultJson */
48+
/** @var \Magento\Framework\Controller\Result\Json $resultJson */
4949
$resultJson = $this->resultJsonFactory->create();
5050
return $resultJson->setData($this->_getDeniedJson());
5151
}

app/code/Magento/Backend/Controller/Adminhtml/Cache.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ protected function _validateTypes(array $types)
7474
$allTypes = array_keys($this->_cacheTypeList->getTypes());
7575
$invalidTypes = array_diff($types, $allTypes);
7676
if (count($invalidTypes) > 0) {
77-
throw new LocalizedException(__("Specified cache type(s) don't exist: " . join(', ', $invalidTypes)));
77+
throw new LocalizedException(__('Specified cache type(s) don\'t exist: %1', join(', ', $invalidTypes)));
7878
}
7979
}
8080

app/code/Magento/Backend/Controller/Adminhtml/Index/GlobalSearch.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
class GlobalSearch extends \Magento\Backend\Controller\Adminhtml\Index
1010
{
1111
/**
12-
* @var \Magento\Framework\Controller\Result\JSONFactory
12+
* @var \Magento\Framework\Controller\Result\JsonFactory
1313
*/
1414
protected $resultJsonFactory;
1515

@@ -22,12 +22,12 @@ class GlobalSearch extends \Magento\Backend\Controller\Adminhtml\Index
2222

2323
/**
2424
* @param \Magento\Backend\App\Action\Context $context
25-
* @param \Magento\Framework\Controller\Result\JSONFactory $resultJsonFactory
25+
* @param \Magento\Framework\Controller\Result\JsonFactory $resultJsonFactory
2626
* @param array $searchModules
2727
*/
2828
public function __construct(
2929
\Magento\Backend\App\Action\Context $context,
30-
\Magento\Framework\Controller\Result\JSONFactory $resultJsonFactory,
30+
\Magento\Framework\Controller\Result\JsonFactory $resultJsonFactory,
3131
array $searchModules = []
3232
) {
3333
$this->_searchModules = $searchModules;
@@ -38,7 +38,7 @@ public function __construct(
3838
/**
3939
* Global Search Action
4040
*
41-
* @return \Magento\Framework\Controller\Result\JSON
41+
* @return \Magento\Framework\Controller\Result\Json
4242
*/
4343
public function execute()
4444
{
@@ -87,7 +87,7 @@ public function execute()
8787
}
8888
}
8989

90-
/** @var \Magento\Framework\Controller\Result\JSON $resultJson */
90+
/** @var \Magento\Framework\Controller\Result\Json $resultJson */
9191
$resultJson = $this->resultJsonFactory->create();
9292
return $resultJson->setData($items);
9393
}

app/code/Magento/Backend/Controller/Adminhtml/System/Account/Save.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ public function execute()
7878
$user->sendPasswordResetNotificationEmail();
7979
}
8080
$this->messageManager->addSuccess(__('The account has been saved.'));
81-
} catch (\Magento\Framework\Validator\ValidatorException $e) {
81+
} catch (\Magento\Framework\Validator\Exception $e) {
8282
$this->messageManager->addMessages($e->getMessages());
8383
if ($e->getMessage()) {
8484
$this->messageManager->addError($e->getMessage());

app/code/Magento/Backend/Model/Auth.php

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77

88
use Magento\Framework\Exception\AuthenticationException;
99
use Magento\Framework\Exception\Plugin\AuthenticationException as PluginAuthenticationException;
10+
use Magento\Framework\Phrase;
1011

1112
/**
1213
* Backend Auth model
@@ -81,7 +82,7 @@ public function __construct(
8182
public function setAuthStorage($storage)
8283
{
8384
if (!$storage instanceof \Magento\Backend\Model\Auth\StorageInterface) {
84-
self::throwException('Authentication storage is incorrect.');
85+
self::throwException(__('Authentication storage is incorrect.'));
8586
}
8687
$this->_authStorage = $storage;
8788
return $this;
@@ -199,12 +200,12 @@ public function isLoggedIn()
199200
/**
200201
* Throws specific Backend Authentication \Exception
201202
*
202-
* @param string $msg
203+
* @param \Magento\Framework\Phrase $msg
203204
* @return void
204205
* @throws \Magento\Framework\Exception\AuthenticationException
205206
* @static
206207
*/
207-
public static function throwException($msg = null)
208+
public static function throwException(Phrase $msg = null)
208209
{
209210
if (is_null($msg)) {
210211
$msg = __('Authentication error occurred.');

app/code/Magento/Backend/Model/View/Layout/GeneratorPool.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,15 @@ class GeneratorPool extends \Magento\Framework\View\Layout\GeneratorPool
2222
* @param ScheduledStructure\Helper $helper
2323
* @param \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig
2424
* @param \Magento\Framework\App\ScopeResolverInterface $scopeResolver
25+
* @param \Psr\Log\LoggerInterface $logger
2526
* @param Filter\Acl $aclFilter
2627
* @param array $generators
2728
*/
2829
public function __construct(
2930
ScheduledStructure\Helper $helper,
3031
\Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig,
3132
\Magento\Framework\App\ScopeResolverInterface $scopeResolver,
33+
\Psr\Log\LoggerInterface $logger,
3234
Filter\Acl $aclFilter,
3335
array $generators = null
3436
) {
@@ -37,6 +39,7 @@ public function __construct(
3739
$helper,
3840
$scopeConfig,
3941
$scopeResolver,
42+
$logger,
4043
$generators
4144
);
4245
}

0 commit comments

Comments
 (0)