Passed
Push — dev ( 2df4e0...9870db )
by Sergey
04:40
created
app/Controllers/ToolsController.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -194,7 +194,7 @@  discard block
 block discarded – undo
194 194
         $results = [];
195 195
 
196 196
         foreach ($array as $key => $value) {
197
-            if (is_array($value) && ! empty($value)) {
197
+            if (is_array($value) && !empty($value)) {
198 198
                 $results = array_merge($results, $this->dotArray($value, $prepend . $key . '.'));
199 199
             } else {
200 200
                 $results[$prepend . $key] = $value;
@@ -211,7 +211,7 @@  discard block
 block discarded – undo
211 211
     {
212 212
         $bytestotal = 0;
213 213
         $path       = realpath($path);
214
-        if ($path!==false && $path!=='' && file_exists($path)) {
214
+        if ($path !== false && $path !== '' && file_exists($path)) {
215 215
             foreach (new RecursiveIteratorIterator(new RecursiveDirectoryIterator($path, FilesystemIterator::SKIP_DOTS)) as $object) {
216 216
                 $bytestotal += $object->getSize();
217 217
             }
Please login to merge, or discard this patch.
bootstrap.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@
 block discarded – undo
23 23
 /**
24 24
  * Ensure vendor libraries exist
25 25
  */
26
-! is_file($admin_autoload = __DIR__ . '/vendor/autoload.php') and exit('Please run: <i>composer install</i> admin plugin');
26
+!is_file($admin_autoload = __DIR__ . '/vendor/autoload.php') and exit('Please run: <i>composer install</i> admin plugin');
27 27
 
28 28
 /**
29 29
  * Register The Auto Loader
Please login to merge, or discard this patch.
app/Controllers/ApiDeliveryRegistryController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -120,7 +120,7 @@
 block discarded – undo
120 120
         $api_token_dir_path  = PATH['project'] . '/tokens' . '/delivery/registry/' . $api_token;
121 121
         $api_token_file_path = $api_token_dir_path . '/token.yaml';
122 122
 
123
-        if (! Filesystem::has($api_token_file_path)) {
123
+        if (!Filesystem::has($api_token_file_path)) {
124 124
 
125 125
             Filesystem::createDir($api_token_dir_path);
126 126
 
Please login to merge, or discard this patch.
app/Controllers/ApiDeliveryEntriesController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -120,7 +120,7 @@
 block discarded – undo
120 120
         $api_token_dir_path  = PATH['project'] . '/tokens' . '/delivery/entries/' . $api_token;
121 121
         $api_token_file_path = $api_token_dir_path . '/token.yaml';
122 122
 
123
-        if (! Filesystem::has($api_token_file_path)) {
123
+        if (!Filesystem::has($api_token_file_path)) {
124 124
 
125 125
             Filesystem::createDir($api_token_dir_path);
126 126
 
Please login to merge, or discard this patch.
app/Controllers/UsersController.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -115,7 +115,7 @@  discard block
 block discarded – undo
115 115
         // Get POST data
116 116
         $data = $request->getParsedBody();
117 117
 
118
-        if (! Filesystem::has($_user_file = PATH['project'] . '/accounts/' . $this->slugify->slugify($data['username']) . '/profile.yaml')) {
118
+        if (!Filesystem::has($_user_file = PATH['project'] . '/accounts/' . $this->slugify->slugify($data['username']) . '/profile.yaml')) {
119 119
             // Generate UUID
120 120
             $uuid = Uuid::uuid4()->toString();
121 121
 
@@ -146,7 +146,7 @@  discard block
 block discarded – undo
146 146
                 $api_delivery_entries_token_dir_path  = PATH['project'] . '/tokens' . '/delivery/entries/' . $api_delivery_entries_token;
147 147
                 $api_delivery_entries_token_file_path = $api_delivery_entries_token_dir_path . '/token.yaml';
148 148
 
149
-                if (! Filesystem::has($api_delivery_entries_token_dir_path)) Filesystem::createDir($api_delivery_entries_token_dir_path);
149
+                if (!Filesystem::has($api_delivery_entries_token_dir_path)) Filesystem::createDir($api_delivery_entries_token_dir_path);
150 150
 
151 151
                 Filesystem::write(
152 152
                     $api_delivery_entries_token_file_path,
@@ -169,7 +169,7 @@  discard block
 block discarded – undo
169 169
                 $api_images_token_dir_path  = PATH['project'] . '/tokens' . '/images/' . $api_images_token;
170 170
                 $api_images_token_file_path = $api_images_token_dir_path . '/token.yaml';
171 171
 
172
-                if (! Filesystem::has($api_images_token_dir_path)) Filesystem::createDir($api_images_token_dir_path);
172
+                if (!Filesystem::has($api_images_token_dir_path)) Filesystem::createDir($api_images_token_dir_path);
173 173
 
174 174
                 Filesystem::write(
175 175
                     $api_images_token_file_path,
@@ -192,7 +192,7 @@  discard block
 block discarded – undo
192 192
                 $api_delivery_registry_token_dir_path  = PATH['project'] . '/tokens' . '/delivery/registry/' . $api_delivery_registry_token;
193 193
                 $api_delivery_registry_token_file_path = $api_delivery_registry_token_dir_path . '/token.yaml';
194 194
 
195
-                if (! Filesystem::has($api_delivery_registry_token_dir_path)) Filesystem::createDir($api_delivery_registry_token_dir_path);
195
+                if (!Filesystem::has($api_delivery_registry_token_dir_path)) Filesystem::createDir($api_delivery_registry_token_dir_path);
196 196
 
197 197
                 Filesystem::write(
198 198
                     $api_delivery_registry_token_file_path,
@@ -221,7 +221,7 @@  discard block
 block discarded – undo
221 221
                 Filesystem::write($custom_flextype_settings_file_path, $this->serializer->encode($custom_flextype_settings_file_data, 'yaml'));
222 222
 
223 223
                 // Create uploads dir for default entries
224
-                if (! Filesystem::has(PATH['project'] . '/uploads/entries/home/')) {
224
+                if (!Filesystem::has(PATH['project'] . '/uploads/entries/home/')) {
225 225
                     Filesystem::createDir(PATH['project'] . '/uploads/entries/home/');
226 226
                 }
227 227
 
Please login to merge, or discard this patch.
Braces   +9 added lines, -3 removed lines patch added patch discarded remove patch
@@ -146,7 +146,9 @@  discard block
 block discarded – undo
146 146
                 $api_delivery_entries_token_dir_path  = PATH['project'] . '/tokens' . '/delivery/entries/' . $api_delivery_entries_token;
147 147
                 $api_delivery_entries_token_file_path = $api_delivery_entries_token_dir_path . '/token.yaml';
148 148
 
149
-                if (! Filesystem::has($api_delivery_entries_token_dir_path)) Filesystem::createDir($api_delivery_entries_token_dir_path);
149
+                if (! Filesystem::has($api_delivery_entries_token_dir_path)) {
150
+                    Filesystem::createDir($api_delivery_entries_token_dir_path);
151
+                }
150 152
 
151 153
                 Filesystem::write(
152 154
                     $api_delivery_entries_token_file_path,
@@ -169,7 +171,9 @@  discard block
 block discarded – undo
169 171
                 $api_images_token_dir_path  = PATH['project'] . '/tokens' . '/images/' . $api_images_token;
170 172
                 $api_images_token_file_path = $api_images_token_dir_path . '/token.yaml';
171 173
 
172
-                if (! Filesystem::has($api_images_token_dir_path)) Filesystem::createDir($api_images_token_dir_path);
174
+                if (! Filesystem::has($api_images_token_dir_path)) {
175
+                    Filesystem::createDir($api_images_token_dir_path);
176
+                }
173 177
 
174 178
                 Filesystem::write(
175 179
                     $api_images_token_file_path,
@@ -192,7 +196,9 @@  discard block
 block discarded – undo
192 196
                 $api_delivery_registry_token_dir_path  = PATH['project'] . '/tokens' . '/delivery/registry/' . $api_delivery_registry_token;
193 197
                 $api_delivery_registry_token_file_path = $api_delivery_registry_token_dir_path . '/token.yaml';
194 198
 
195
-                if (! Filesystem::has($api_delivery_registry_token_dir_path)) Filesystem::createDir($api_delivery_registry_token_dir_path);
199
+                if (! Filesystem::has($api_delivery_registry_token_dir_path)) {
200
+                    Filesystem::createDir($api_delivery_registry_token_dir_path);
201
+                }
196 202
 
197 203
                 Filesystem::write(
198 204
                     $api_delivery_registry_token_file_path,
Please login to merge, or discard this patch.
app/Controllers/ApiImagesController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -112,7 +112,7 @@
 block discarded – undo
112 112
         $api_token_dir_path  = PATH['project'] . '/tokens' . '/images/' . $api_token;
113 113
         $api_token_file_path = $api_token_dir_path . '/token.yaml';
114 114
 
115
-        if (! Filesystem::has($api_token_file_path)) {
115
+        if (!Filesystem::has($api_token_file_path)) {
116 116
 
117 117
             Filesystem::createDir($api_token_dir_path);
118 118
 
Please login to merge, or discard this patch.
app/Controllers/ApiManagementEntriesController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -120,7 +120,7 @@
 block discarded – undo
120 120
         $api_token_dir_path  = PATH['project'] . '/tokens' . '/management/entries/' . $api_token;
121 121
         $api_token_file_path = $api_token_dir_path . '/token.yaml';
122 122
 
123
-        if (! Filesystem::has($api_token_file_path)) {
123
+        if (!Filesystem::has($api_token_file_path)) {
124 124
 
125 125
             Filesystem::createDir($api_token_dir_path);
126 126
 
Please login to merge, or discard this patch.
app/Controllers/ApiAccessController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -112,7 +112,7 @@
 block discarded – undo
112 112
         $api_token_dir_path  = PATH['project'] . '/tokens' . '/access/' . $api_token;
113 113
         $api_token_file_path = $api_token_dir_path . '/token.yaml';
114 114
 
115
-        if (! Filesystem::has($api_token_file_path)) {
115
+        if (!Filesystem::has($api_token_file_path)) {
116 116
 
117 117
             Filesystem::createDir($api_token_dir_path);
118 118
 
Please login to merge, or discard this patch.
app/Controllers/ApiController.php 1 patch
Indentation   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -32,22 +32,22 @@
 block discarded – undo
32 32
                 'menu_item' => 'api',
33 33
                 'api_list' => [
34 34
                                 'delivery' => [
35
-                                  'title' => __('admin_delivery'),
36
-                                  'icon' => 'fas fa-truck'
35
+                                    'title' => __('admin_delivery'),
36
+                                    'icon' => 'fas fa-truck'
37 37
                                 ],
38 38
                                 'images' => [
39
-                                  'title' => __('admin_images'),
40
-                                  'icon' => 'far fa-images'
39
+                                    'title' => __('admin_images'),
40
+                                    'icon' => 'far fa-images'
41 41
                                 ],
42 42
                                 'management' => [
43
-                                  'title' => __('admin_management'),
44
-                                  'icon' => 'fas fa-user-cog'
43
+                                    'title' => __('admin_management'),
44
+                                    'icon' => 'fas fa-user-cog'
45 45
                                 ],
46 46
                                 'access' => [
47
-                                  'title' => __('admin_access'),
48
-                                  'icon' => 'fas fa-user-shield'
47
+                                    'title' => __('admin_access'),
48
+                                    'icon' => 'fas fa-user-shield'
49
+                                ],
49 50
                                 ],
50
-                               ],
51 51
                 'links' =>  [
52 52
                     'api' => [
53 53
                         'link' => $this->router->pathFor('admin.api.index'),
Please login to merge, or discard this patch.