Replies: 1 comment
-
That's not possible... PHP would break over a non existent variable. Even wrapped inside another function that has $query, this would not work as both statements are executed before passed to the when/unless methods... |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Would it be nice if we build the
->when()
and->unless()
for model queries differently or let those method accept Builder class?From this:
To this:
Beta Was this translation helpful? Give feedback.
All reactions