@@ -14,7 +14,7 @@ discard block |
||
| 14 | 14 | public function boot() |
| 15 | 15 | { |
| 16 | 16 | $this->publishes([ |
| 17 | - __DIR__.'/../config/query-updater.php' => config_path('query-updater.php'), |
|
| 17 | + __DIR__ . '/../config/query-updater.php' => config_path('query-updater.php'), |
|
| 18 | 18 | ], 'query-updater'); |
| 19 | 19 | } |
| 20 | 20 | |
@@ -25,6 +25,6 @@ discard block |
||
| 25 | 25 | */ |
| 26 | 26 | public function register() |
| 27 | 27 | { |
| 28 | - $this->mergeConfigFrom(__DIR__.'/../config/query-updater.php', 'query-updater'); |
|
| 28 | + $this->mergeConfigFrom(__DIR__ . '/../config/query-updater.php', 'query-updater'); |
|
| 29 | 29 | } |
| 30 | 30 | } |
@@ -34,7 +34,7 @@ discard block |
||
| 34 | 34 | return []; |
| 35 | 35 | } |
| 36 | 36 | |
| 37 | - public static function for(Model $model, $request = null): self |
|
| 37 | + public static function for (Model $model, $request = null): self |
|
| 38 | 38 | { |
| 39 | 39 | return new static($model, $request ?? request()); |
| 40 | 40 | } |
@@ -43,7 +43,7 @@ discard block |
||
| 43 | 43 | { |
| 44 | 44 | $fields = $this->composeFields($fields); |
| 45 | 45 | |
| 46 | - $fields->each(function ($field) { |
|
| 46 | + $fields->each(function($field) { |
|
| 47 | 47 | if ($this->fieldExists($field->getName()) && $this->allowedField($field->getName())) { |
| 48 | 48 | $this->model->{$field->getName()} = $field->getValue(); |
| 49 | 49 | } |
@@ -76,7 +76,7 @@ discard block |
||
| 76 | 76 | { |
| 77 | 77 | return collect($fields) |
| 78 | 78 | ->flatten() |
| 79 | - ->map(function ($field) { |
|
| 79 | + ->map(function($field) { |
|
| 80 | 80 | if (empty($field)) { |
| 81 | 81 | return false; |
| 82 | 82 | } else { |
@@ -93,7 +93,7 @@ discard block |
||
| 93 | 93 | return $field; |
| 94 | 94 | } |
| 95 | 95 | }) |
| 96 | - ->filter(function ($field) { |
|
| 96 | + ->filter(function($field) { |
|
| 97 | 97 | return $field instanceof AbstractFilter; |
| 98 | 98 | }); |
| 99 | 99 | } |