Scrutinizer GitHub App not installed

We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.

Install GitHub App

Completed
Pull Request — master (#1935)
by Cristian
06:00 queued 03:19
created
tests/Unit/CrudPanel/CrudPanelUpdateTest.php 1 patch
Unused Use Statements   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -2,10 +2,10 @@
 block discarded – undo
2 2
 
3 3
 namespace Backpack\CRUD\Tests\Unit\CrudPanel;
4 4
 
5
-use Faker\Factory;
6
-use Illuminate\Support\Facades\DB;
7 5
 use Backpack\CRUD\Tests\Unit\Models\User;
6
+use Faker\Factory;
8 7
 use Illuminate\Database\Eloquent\ModelNotFoundException;
8
+use Illuminate\Support\Facades\DB;
9 9
 
10 10
 class CrudPanelUpdateTest extends BaseDBCrudPanelTest
11 11
 {
Please login to merge, or discard this patch.
src/ModelTraits/SpatieTranslatable/SlugService.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -49,7 +49,7 @@
 block discarded – undo
49 49
      */
50 50
     protected function makeSlugUnique(string $slug, array $config, string $attribute): string
51 51
     {
52
-        if (! $config['unique']) {
52
+        if (!$config['unique']) {
53 53
             return $slug;
54 54
         }
55 55
 
Please login to merge, or discard this patch.
src/PanelTraits/FakeFields.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
                 $fakeFieldKey = isset($field['store_in']) ? $field['store_in'] : 'extras';
30 30
                 $this->addCompactedField($requestInput, $field['name'], $fakeFieldKey);
31 31
 
32
-                if (! in_array($fakeFieldKey, $compactedFakeFields)) {
32
+                if (!in_array($fakeFieldKey, $compactedFakeFields)) {
33 33
                     $compactedFakeFields[] = $fakeFieldKey;
34 34
                 }
35 35
             }
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
 
38 38
         // json_encode all fake_value columns if applicable in the database, so they can be properly stored and interpreted
39 39
         foreach ($compactedFakeFields as $value) {
40
-            if (! (property_exists($this->model, 'translatable') && in_array($value, $this->model->getTranslatableAttributes(), true)) && $this->model->shouldEncodeFake($value)) {
40
+            if (!(property_exists($this->model, 'translatable') && in_array($value, $this->model->getTranslatableAttributes(), true)) && $this->model->shouldEncodeFake($value)) {
41 41
                 $requestInput[$value] = json_encode($requestInput[$value]);
42 42
             }
43 43
         }
Please login to merge, or discard this patch.
Doc Comments   -2 removed lines patch added patch discarded remove patch
@@ -10,8 +10,6 @@
 block discarded – undo
10 10
      * plus the '_token' and 'redirect_after_save' variables.
11 11
      *
12 12
      * @param array    $requestInput The request input.
13
-     * @param string   $form         The CRUD form. Can be 'create' or 'update' . Default is 'create'.
14
-     * @param int|bool $id           The CRUD entry id in the case of the 'update' form.
15 13
      *
16 14
      * @see \Illuminate\Http\Request::all() For an example on how to get the request input.
17 15
      *
Please login to merge, or discard this patch.
src/PanelTraits/Create.php 3 patches
Unused Use Statements   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,8 +2,8 @@
 block discarded – undo
2 2
 
3 3
 namespace Backpack\CRUD\PanelTraits;
4 4
 
5
-use Illuminate\Database\Eloquent\Relations\HasOne;
6 5
 use Illuminate\Database\Eloquent\Relations\BelongsTo;
6
+use Illuminate\Database\Eloquent\Relations\HasOne;
7 7
 
8 8
 trait Create
9 9
 {
Please login to merge, or discard this patch.
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -159,7 +159,7 @@
 block discarded – undo
159 159
      * @param \Illuminate\Database\Eloquent\Model $item          The current CRUD model.
160 160
      * @param array                               $formattedData The form data.
161 161
      *
162
-     * @return bool|null
162
+     * @return false|null
163 163
      */
164 164
     private function createRelationsForItem($item, $formattedData)
165 165
     {
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -81,7 +81,7 @@  discard block
 block discarded – undo
81 81
     {
82 82
         $all_relation_fields = $this->getRelationFields();
83 83
 
84
-        return array_where($all_relation_fields, function ($value, $key) {
84
+        return array_where($all_relation_fields, function($value, $key) {
85 85
             return isset($value['pivot']) && $value['pivot'];
86 86
         });
87 87
     }
@@ -156,7 +156,7 @@  discard block
 block discarded – undo
156 156
      */
157 157
     private function createRelationsForItem($item, $formattedData)
158 158
     {
159
-        if (! isset($formattedData['relations'])) {
159
+        if (!isset($formattedData['relations'])) {
160 160
             return false;
161 161
         }
162 162
 
@@ -213,11 +213,11 @@  discard block
 block discarded – undo
213 213
                 $key = implode('.relations.', explode('.', $relationField['entity']));
214 214
                 $fieldData = array_get($relationData, 'relations.'.$key, []);
215 215
 
216
-                if (! array_key_exists('model', $fieldData)) {
216
+                if (!array_key_exists('model', $fieldData)) {
217 217
                     $fieldData['model'] = $relationField['model'];
218 218
                 }
219 219
 
220
-                if (! array_key_exists('parent', $fieldData)) {
220
+                if (!array_key_exists('parent', $fieldData)) {
221 221
                     $fieldData['parent'] = $this->getRelationModel($relationField['entity'], -1);
222 222
                 }
223 223
 
Please login to merge, or discard this patch.
src/PanelTraits/Update.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
 
52 52
         foreach ($fields as &$field) {
53 53
             // set the value
54
-            if (! isset($field['value'])) {
54
+            if (!isset($field['value'])) {
55 55
                 if (isset($field['subfields'])) {
56 56
                     $field['value'] = [];
57 57
                     foreach ($field['subfields'] as $subfield) {
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
         }
65 65
 
66 66
         // always have a hidden input for the entry id
67
-        if (! array_key_exists('id', $fields)) {
67
+        if (!array_key_exists('id', $fields)) {
68 68
             $fields['id'] = [
69 69
                 'name'  => $entry->getKeyName(),
70 70
                 'value' => $entry->getKey(),
@@ -87,7 +87,7 @@  discard block
 block discarded – undo
87 87
     {
88 88
         if (isset($field['entity'])) {
89 89
             $relationArray = explode('.', $field['entity']);
90
-            $relatedModel = array_reduce(array_splice($relationArray, 0, -1), function ($obj, $method) {
90
+            $relatedModel = array_reduce(array_splice($relationArray, 0, -1), function($obj, $method) {
91 91
                 return $obj->{$method} ? $obj->{$method} : $obj;
92 92
             }, $model);
93 93
 
Please login to merge, or discard this patch.
src/resources/views/filters/range.blade.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -9,8 +9,8 @@
 block discarded – undo
9 9
 					<?php
10 10
 						$from = '';
11 11
 						$to = '';
12
-						if($filter->currentValue) {
13
-							$range = (array)json_decode($filter->currentValue);
12
+						if ($filter->currentValue) {
13
+							$range = (array) json_decode($filter->currentValue);
14 14
 							$from = $range['from'];
15 15
 							$to = $range['to'];
16 16
 						}
Please login to merge, or discard this patch.
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -7,14 +7,14 @@
 block discarded – undo
7 7
 
8 8
 			<div class="form-group backpack-filter mb-0">
9 9
 					<?php
10
-						$from = '';
11
-						$to = '';
12
-						if($filter->currentValue) {
13
-							$range = (array)json_decode($filter->currentValue);
14
-							$from = $range['from'];
15
-							$to = $range['to'];
16
-						}
17
-					?>
10
+                        $from = '';
11
+                        $to = '';
12
+                        if($filter->currentValue) {
13
+                            $range = (array)json_decode($filter->currentValue);
14
+                            $from = $range['from'];
15
+                            $to = $range['to'];
16
+                        }
17
+                    ?>
18 18
 					<div class="input-group">
19 19
 				        <input class="form-control pull-right from"
20 20
 				        		type="number"
Please login to merge, or discard this patch.
src/resources/lang/ar/crud.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@
 block discarded – undo
13 13
     |
14 14
     */
15 15
 
16
- return [
16
+    return [
17 17
     'infoFiltered' => '(filtered from _MAX_ total entries)',
18 18
     'thousands' => ',',
19 19
     'admin' => 'المشرف',
Please login to merge, or discard this patch.
src/public/ckeditor/samples/old/assets/posteddata.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -25,9 +25,9 @@
 block discarded – undo
25 25
 		</thead>
26 26
 <?php
27 27
 
28
-if (! empty($_POST)) {
28
+if (!empty($_POST)) {
29 29
     foreach ($_POST as $key => $value) {
30
-        if ((! is_string($value) && ! is_numeric($value)) || ! is_string($key)) {
30
+        if ((!is_string($value) && !is_numeric($value)) || !is_string($key)) {
31 31
             continue;
32 32
         }
33 33
 
Please login to merge, or discard this patch.
src/app/Console/Commands/Install.php 3 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@
 block discarded – undo
53 53
                     $this->executeProcess('mkdir -p public/uploads');
54 54
                     break;
55 55
                 case '\\': // windows
56
-                    if (! file_exists('public\uploads')) {
56
+                    if (!file_exists('public\uploads')) {
57 57
                         $this->executeProcess('mkdir public\uploads');
58 58
                     }
59 59
                     break;
Please login to merge, or discard this patch.
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@
 block discarded – undo
30 30
     /**
31 31
      * Execute the console command.
32 32
      *
33
-     * @return mixed
33
+     * @return false|null
34 34
      */
35 35
     public function handle()
36 36
     {
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,6 @@
 block discarded – undo
2 2
 
3 3
 namespace Backpack\CRUD\app\Console\Commands;
4 4
 
5
-use Illuminate\Console\Command;
6 5
 use Backpack\Base\app\Console\Commands\Install as BaseInstall;
7 6
 
8 7
 class Install extends BaseInstall
Please login to merge, or discard this patch.