You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think this is because the combine() method changes the shape of the collection. I didn't find that method on the stubs, so maybe this is too much magic for larastan.
I tried adding a phpdoc after the combine() method to inform larastan about the new shape, but it's not working, is there any way to inform phpstan about the new shape of the collection?
Will use that as a workaround, better than ignoring the line. It would be good that Larastan could understand combine so we could maintain the fluent syntax. Do you think this can be done? I have not enough knowledge but if this is doable, I can put this into my TODO list (no promises, sorry!)
As of Larastan 2 all the collection related stubs are moved to Laravel core. So please test this with Laravel 9 and Larastan 2, and if the error still happens please open an issue on Laravel repo. Thanks.
--level
used: 8Description
Running the code below, I get:
I think this is because the
combine()
method changes the shape of the collection. I didn't find that method on the stubs, so maybe this is too much magic for larastan.I tried adding a phpdoc after the combine() method to inform larastan about the new shape, but it's not working, is there any way to inform phpstan about the new shape of the collection?
Laravel code where the issue was found
The text was updated successfully, but these errors were encountered: