File tree Expand file tree Collapse file tree 1 file changed +11
-6
lines changed
app/code/Magento/AdminNotification/Controller/Adminhtml/System/Message Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Original file line number Diff line number Diff line change 1
1
<?php
2
2
/**
3
3
*
4
- * @copyright Copyright (c) 2014 X.commerce, Inc. (http://www.magentocommerce.com)
4
+ *@copyright Copyright(c) 2014 X.commerce, Inc. (http://www.magentocommerce.com)
5
5
*/
6
6
namespace Magento \AdminNotification \Controller \Adminhtml \System \Message ;
7
7
@@ -13,10 +13,11 @@ class ListAction extends \Magento\Backend\App\AbstractAction
13
13
public function execute ()
14
14
{
15
15
$ severity = $ this ->getRequest ()->getParam ('severity ' );
16
- $ default = array (
16
+ $ default = [
17
17
'severity ' => $ severity ,
18
- 'text ' => 'All recent issues have been fixed. Please refresh the screen for an update. ' ,
19
- );
18
+ 'text ' => 'All recent issues have been fixed. '
19
+ .'Please refresh the screen for an update. ' ,
20
+ ];
20
21
$ messageCollection = $ this ->_objectManager ->get (
21
22
'Magento\AdminNotification\Model\Resource\System\Message\Collection '
22
23
);
@@ -25,13 +26,17 @@ public function execute()
25
26
}
26
27
$ result = [];
27
28
foreach ($ messageCollection ->getItems () as $ item ) {
28
- $ result [] = ['severity ' => $ item ->getSeverity (), 'text ' => $ item ->getText ()];
29
+ $ result [] = [
30
+ 'severity ' => $ item ->getSeverity (),
31
+ 'text ' => $ item ->getText (),
32
+ ];
29
33
}
30
34
if (empty ($ result )) {
31
35
$ result [] = $ default ;
32
36
}
33
37
$ this ->getResponse ()->representJson (
34
- $ this ->_objectManager ->get ('Magento\Core\Helper\Data ' )->jsonEncode ($ result )
38
+ $ this ->_objectManager ->get ('Magento\Core\Helper\Data ' )
39
+ ->jsonEncode ($ result )
35
40
);
36
41
}
37
42
}
You can’t perform that action at this time.
0 commit comments