Test Setup Failed
Branch master (193986)
by Andrey
07:40
created
widgets/Alert.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
      * @var array the options for rendering the close button tag.
42 42
      * Array will be passed to [[\yii\bootstrap\Alert::closeButton]].
43 43
      */
44
-    public $closeButton = [];
44
+    public $closeButton = [ ];
45 45
 
46 46
 
47 47
     /**
@@ -51,20 +51,20 @@  discard block
 block discarded – undo
51 51
     {
52 52
         $session = Yii::$app->session;
53 53
         $flashes = $session->getAllFlashes();
54
-        $appendClass = isset($this->options['class']) ? ' ' . $this->options['class'] : '';
54
+        $appendClass = isset($this->options[ 'class' ]) ? ' ' . $this->options[ 'class' ] : '';
55 55
 
56 56
         foreach ($flashes as $type => $flash) {
57
-            if (!isset($this->alertTypes[$type])) {
57
+            if (!isset($this->alertTypes[ $type ])) {
58 58
                 continue;
59 59
             }
60 60
 
61
-            foreach ((array) $flash as $i => $message) {
61
+            foreach ((array)$flash as $i => $message) {
62 62
                 echo \yii\bootstrap\Alert::widget([
63 63
                     'body' => $message,
64 64
                     'closeButton' => $this->closeButton,
65 65
                     'options' => array_merge($this->options, [
66 66
                         'id' => $this->getId() . '-' . $type . '-' . $i,
67
-                        'class' => $this->alertTypes[$type] . $appendClass,
67
+                        'class' => $this->alertTypes[ $type ] . $appendClass,
68 68
                     ]),
69 69
                 ]);
70 70
             }
Please login to merge, or discard this patch.
traits/ThumbnailTrait.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -26,11 +26,11 @@  discard block
 block discarded – undo
26 26
      *
27 27
      * @return mixed
28 28
      */
29
-    public function getDefaultThumbImage(array $options = [])
29
+    public function getDefaultThumbImage(array $options = [ ])
30 30
     {
31 31
         $thumbnailModel = $this->getThumbnailModel();
32 32
 
33
-        if (null === $thumbnailModel){
33
+        if (null === $thumbnailModel) {
34 34
             return null;
35 35
         }
36 36
 
@@ -40,8 +40,8 @@  discard block
 block discarded – undo
40 40
             return null;
41 41
         }
42 42
 
43
-        if (empty($options['alt'])) {
44
-            $options['alt'] = $thumbnailModel->alt;
43
+        if (empty($options[ 'alt' ])) {
44
+            $options[ 'alt' ] = $thumbnailModel->alt;
45 45
         }
46 46
 
47 47
         return Html::img($url, $options);
Please login to merge, or discard this patch.
traits/AdminBeforeActionTrait.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -31,12 +31,12 @@
 block discarded – undo
31 31
     {
32 32
         $this->view->mainMenuConfig = require __DIR__ . '/../config/admin/main-menu.php';
33 33
 
34
-        $this->view->profileLink = '/admin/users/view?id='.Yii::$app->getUser()->id;
34
+        $this->view->profileLink = '/admin/users/view?id=' . Yii::$app->getUser()->id;
35 35
 
36 36
         $this->urlPrefix = '/' . $this->module->id . '/' . $action->controller->id . '/';
37 37
 
38 38
         if (array_key_exists($action->controller->id, $this->neighborControllers)) {
39
-            $this->urlPrefixNeighbor = '/' . $this->module->id . '/' . $this->neighborControllers[$action->controller->id] . '/';
39
+            $this->urlPrefixNeighbor = '/' . $this->module->id . '/' . $this->neighborControllers[ $action->controller->id ] . '/';
40 40
         }
41 41
 
42 42
         return parent::beforeAction($action);
Please login to merge, or discard this patch.
traits/ResponseTrait.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -52,7 +52,7 @@
 block discarded – undo
52 52
         int $statusCode = 200): array {
53 53
 
54 54
         if (null === $data) {
55
-            $data = (object)[];
55
+            $data = (object)[ ];
56 56
         }
57 57
 
58 58
         \Yii::$app->response->statusCode = $statusCode;
Please login to merge, or discard this patch.
models/HomeSearch.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
     {
20 20
         return [
21 21
             [
22
-                ['id'],
22
+                [ 'id' ],
23 23
                 'integer',
24 24
             ],
25 25
             [
Please login to merge, or discard this patch.
models/UserValidate.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -119,16 +119,16 @@  discard block
 block discarded – undo
119 119
                 'unique',
120 120
                 'skipOnError'     => true,
121 121
                 'targetClass'     => \Yii::$app->user->identityClass,
122
-                'targetAttribute' => ['login' => 'login'],
123
-                'filter' => $this->getScenario() == self::SCENARIO_UPDATE ? 'id != '.$this->id : ''
122
+                'targetAttribute' => [ 'login' => 'login' ],
123
+                'filter' => $this->getScenario() == self::SCENARIO_UPDATE ? 'id != ' . $this->id : ''
124 124
             ],
125 125
             [
126 126
                 'email',
127 127
                 'unique',
128 128
                 'skipOnError'     => true,
129 129
                 'targetClass'     => \Yii::$app->user->identityClass,
130
-                'targetAttribute' => ['email' => 'email'],
131
-                'filter' => $this->getScenario() == self::SCENARIO_UPDATE ? 'id != '.$this->id : ''
130
+                'targetAttribute' => [ 'email' => 'email' ],
131
+                'filter' => $this->getScenario() == self::SCENARIO_UPDATE ? 'id != ' . $this->id : ''
132 132
             ],
133 133
             [
134 134
                 'password',
@@ -160,7 +160,7 @@  discard block
 block discarded – undo
160 160
                 'exist',
161 161
                 'skipOnError' => true,
162 162
                 'targetClass' => Position::class,
163
-                'targetAttribute' => ['position_id' => 'id']
163
+                'targetAttribute' => [ 'position_id' => 'id' ]
164 164
             ],
165 165
         ];
166 166
     }
Please login to merge, or discard this patch.
models/PageSearch.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
     {
20 20
         return [
21 21
             [
22
-                ['id'],
22
+                [ 'id' ],
23 23
                 'integer',
24 24
             ],
25 25
             [
Please login to merge, or discard this patch.
models/Feedback.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -174,7 +174,7 @@
 block discarded – undo
174 174
         if ($this->save()) {
175 175
             Yii::$app->mailer->compose()
176 176
                 ->setTo($email)
177
-                ->setFrom([$this->email => $this->name])
177
+                ->setFrom([ $this->email => $this->name ])
178 178
                 ->setSubject('New message from bizness-develop feedback. ' . $this->subject)
179 179
                 ->setTextBody($this->message)
180 180
                 ->send();
Please login to merge, or discard this patch.
models/ProductSearch.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -78,10 +78,10 @@
 block discarded – undo
78 78
             'active' => $this->active,
79 79
         ]);
80 80
 
81
-        $query->andFilterWhere(['like', 'title', $this->title]);
81
+        $query->andFilterWhere([ 'like', 'title', $this->title ]);
82 82
 
83 83
         $pagination = new Pagination([
84
-            'defaultPageSize' => Yii::$app->params['defaultPageSize'],
84
+            'defaultPageSize' => Yii::$app->params[ 'defaultPageSize' ],
85 85
             'totalCount' => $query->count(),
86 86
         ]);
87 87
 
Please login to merge, or discard this patch.