| Conditions | 1 |
| Paths | 1 |
| Total Lines | 22 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 16 | public function boot() |
||
| 17 | { |
||
| 18 | $this->publishes([ |
||
| 19 | __DIR__.'/../config/sarala.php' => config_path('sarala.php'), |
||
| 20 | ], 'config'); |
||
| 21 | |||
| 22 | Request::macro('filters', function () { |
||
| 23 | return new QueryParamBag($this, 'filter'); |
||
|
|
|||
| 24 | }); |
||
| 25 | |||
| 26 | Request::macro('includes', function () { |
||
| 27 | return new QueryParamBag($this, 'include'); |
||
| 28 | }); |
||
| 29 | |||
| 30 | Request::macro('fields', function () { |
||
| 31 | return new Fields($this); |
||
| 32 | }); |
||
| 33 | |||
| 34 | Request::macro('sorts', function () { |
||
| 35 | return new Sorts($this); |
||
| 36 | }); |
||
| 37 | } |
||
| 38 | |||
| 54 |
It seems like the type of the argument is not accepted by the function/method which you are calling.
In some cases, in particular if PHP’s automatic type-juggling kicks in this might be fine. In other cases, however this might be a bug.
We suggest to add an explicit type cast like in the following example: