Passed
Push — develop ( a38b1e...37b382 )
by Andrew
05:06
created
src/controllers/SettingsController.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
     // Protected Properties
40 40
     // =========================================================================
41 41
 
42
-    protected $allowAnonymous = [];
42
+    protected $allowAnonymous = [ ];
43 43
 
44 44
     // Public Methods
45 45
     // =========================================================================
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
      */
55 55
     public function actionPluginSettings($settings = null): Response
56 56
     {
57
-        $variables = [];
57
+        $variables = [ ];
58 58
         PermissionHelper::controllerPermissionCheck('retour:settings');
59 59
         if ($settings === null) {
60 60
             $settings = Retour::$settings;
@@ -69,16 +69,16 @@  discard block
 block discarded – undo
69 69
         } catch (InvalidConfigException $e) {
70 70
             Craft::error($e->getMessage(), __METHOD__);
71 71
         }
72
-        $variables['baseAssetsUrl'] = Craft::$app->assetManager->getPublishedUrl(
72
+        $variables[ 'baseAssetsUrl' ] = Craft::$app->assetManager->getPublishedUrl(
73 73
             '@nystudio107/retour/assetbundles/retour/dist',
74 74
             true
75 75
         );
76 76
         // Basic variables
77
-        $variables['fullPageForm'] = true;
78
-        $variables['docsUrl'] = self::DOCUMENTATION_URL;
79
-        $variables['pluginName'] = $pluginName;
80
-        $variables['title'] = $templateTitle;
81
-        $variables['crumbs'] = [
77
+        $variables[ 'fullPageForm' ] = true;
78
+        $variables[ 'docsUrl' ] = self::DOCUMENTATION_URL;
79
+        $variables[ 'pluginName' ] = $pluginName;
80
+        $variables[ 'title' ] = $templateTitle;
81
+        $variables[ 'crumbs' ] = [
82 82
             [
83 83
                 'label' => $pluginName,
84 84
                 'url' => UrlHelper::cpUrl('retour'),
@@ -88,9 +88,9 @@  discard block
 block discarded – undo
88 88
                 'url' => UrlHelper::cpUrl('retour/settings'),
89 89
             ],
90 90
         ];
91
-        $variables['docTitle'] = "{$pluginName} - {$templateTitle}";
92
-        $variables['selectedSubnavItem'] = 'settings';
93
-        $variables['settings'] = $settings;
91
+        $variables[ 'docTitle' ] = "{$pluginName} - {$templateTitle}";
92
+        $variables[ 'selectedSubnavItem' ] = 'settings';
93
+        $variables[ 'settings' ] = $settings;
94 94
 
95 95
         // Render the template
96 96
         return $this->renderTemplate('retour/settings', $variables);
@@ -110,7 +110,7 @@  discard block
 block discarded – undo
110 110
         PermissionHelper::controllerPermissionCheck('retour:settings');
111 111
         $this->requirePostRequest();
112 112
         $pluginHandle = Craft::$app->getRequest()->getRequiredBodyParam('pluginHandle');
113
-        $settings = Craft::$app->getRequest()->getBodyParam('settings', []);
113
+        $settings = Craft::$app->getRequest()->getBodyParam('settings', [ ]);
114 114
         $plugin = Craft::$app->getPlugins()->getPlugin($pluginHandle);
115 115
 
116 116
         if ($plugin === null) {
Please login to merge, or discard this patch.