Test Setup Failed
Branch master (193986)
by Andrey
07:40
created
controllers/admin/FeedbackController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
     public function afterAction($action, $result)
28 28
     {
29 29
         if ($action->id == 'view') {
30
-            $modelId = $action->controller->actionParams['id'];
30
+            $modelId = $action->controller->actionParams[ 'id' ];
31 31
             Feedback::fixReadStatus((int)$modelId);
32 32
         }
33 33
 
Please login to merge, or discard this patch.
controllers/ajax/RecaptchaAjaxController.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
      */
35 35
     public function init()
36 36
     {
37
-        $this->recaptchaDriver = new ReCaptcha(Yii::$app->params['captcha']['secret_key']);
37
+        $this->recaptchaDriver = new ReCaptcha(Yii::$app->params[ 'captcha' ][ 'secret_key' ]);
38 38
     }
39 39
 
40 40
     /**
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
     public function verbs()
72 72
     {
73 73
         return [
74
-            'validate' => ['POST']
74
+            'validate' => [ 'POST' ]
75 75
         ];
76 76
     }
77 77
 
Please login to merge, or discard this patch.
controllers/ajax/FeedbackAjaxController.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
     public function verbs()
58 58
     {
59 59
         return [
60
-            'send' => ['POST']
60
+            'send' => [ 'POST' ]
61 61
         ];
62 62
     }
63 63
 
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
         $feedback->setScenario(Feedback::SCENARIO_FEEDBACK);
98 98
         $feedback->setAttributes($request->post(), false);
99 99
 
100
-        if ($feedback->contact(Yii::$app->params['adminEmail'])) {
100
+        if ($feedback->contact(Yii::$app->params[ 'adminEmail' ])) {
101 101
 
102 102
             return $this->getSuccessResponse(Yii::t('feedback', 'You have successfully sent your message.'));
103 103
         } else {
Please login to merge, or discard this patch.
helpers/InitialUserSettings.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -63,8 +63,8 @@  discard block
 block discarded – undo
63 63
     private static function setUserStatus(TableSchema $settingsTableSchema, $settings, IdentityInterface $user): void
64 64
     {
65 65
         if (in_array('initUserStatus', $settingsTableSchema->columnNames)) {
66
-            $user->status = is_array($settings) && null !== $settings['initUserStatus'] ?
67
-                $settings['initUserStatus'] : self::INIT_USER_STATUS;
66
+            $user->status = is_array($settings) && null !== $settings[ 'initUserStatus' ] ?
67
+                $settings[ 'initUserStatus' ] : self::INIT_USER_STATUS;
68 68
             $user->save();
69 69
         } else {
70 70
             Yii::error('Field "initUserStatus" does not exists in "settings" table to set initial user status.');
@@ -93,11 +93,11 @@  discard block
 block discarded – undo
93 93
                 ]);
94 94
             }
95 95
 
96
-            if (!is_array($settings) || null === $settings['initUserRole']) {
96
+            if (!is_array($settings) || null === $settings[ 'initUserRole' ]) {
97 97
                 $initUserRole = self::INIT_USER_ROLE;
98 98
                 Yii::error('Can not get field value of "initUserRole" from "settings" table to set initial user role.');
99 99
             } else {
100
-                $initUserRole = $settings['initUserRole'];
100
+                $initUserRole = $settings[ 'initUserRole' ];
101 101
             }
102 102
 
103 103
             $authManager->assign(
Please login to merge, or discard this patch.
helpers/BaseHelper.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -30,11 +30,11 @@
 block discarded – undo
30 30
         $fields = array('HTTP_CLIENT_IP', 'HTTP_X_REAL_IP', 'HTTP_X_FORWARDED_FOR', 'REMOTE_ADDR');
31 31
 
32 32
         $ip = "0.0.0.0";
33
-        foreach($fields as $k)
33
+        foreach ($fields as $k)
34 34
         {
35
-            if(!empty($_SERVER[$k]) && ip2long($_SERVER[$k]) != false)
35
+            if (!empty($_SERVER[ $k ]) && ip2long($_SERVER[ $k ]) != false)
36 36
             {
37
-                $ip = $_SERVER[$k];
37
+                $ip = $_SERVER[ $k ];
38 38
             }
39 39
         }
40 40
 
Please login to merge, or discard this patch.