--level used: 5Parameter #2 $callback of method Illuminate\Database\Eloquent\Builder<App\Resource>::when() expects
(callable(Illuminate\Database\Eloquent\Builder<App\Resource>, mixed): null)|Illuminate\Database\Eloquent\Builder<App\Resource>,
Closure(Illuminate\Database\Eloquent\Builder): void given.
Resource::query()
->when($request->filled('stuff'), function ($query) use ($request) {
$query->where('stuff', $request->input('stuff'));
});
I believe instead of null return we should also return void
https://github.com/nunomaduro/larastan/commit/3b32c74a63ce36f85d5b0434725a59e0dcd74292#diff-cda4a8378b7ebd0f5aa8a5a9ae53a08e48d436e67928064bf28963f969dd93e0R192
Thank you.
What is your Larastan (this project) version?
Latest version
On Sat, Mar 20, 2021 at 1:45 AM Viktor Szépe @.*>
wrote:
Thank you.
What is your Larastan (this project) version?—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/nunomaduro/larastan/issues/799#issuecomment-803255428,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AHZ2XFPXXTCNOZ6UNWF55WLTEQY7HANCNFSM4ZP6ZINA
.
So what about this bug?
We welcome contributors.
Most helpful comment
Latest version
On Sat, Mar 20, 2021 at 1:45 AM Viktor Szépe @.*>
wrote: