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
Inside one of my projects, I've found the if I gave a valid Model instance to the Authorize middleware, the Model is not recognized as one and the $request->route($model); code is called.
This call will fail because my $model variable is an object and the route method need a string as parameter name.
I think that it'll be better if the getGateArguments method in Authorize middleware verify if the given model is not already a Model instance...
I can make a PR but as it concerned 3 different branches what's the right way to do ? Create a PR for each version ?
Steps To Reproduce:
I created an extension of the Authorize middleware like this which failed recognizing the model :
Description:
Inside one of my projects, I've found the if I gave a valid
Model
instance to the Authorize middleware, theModel
is not recognized as one and the$request->route($model);
code is called.This call will fail because my
$model
variable is an object and theroute
method need a string as parameter name.I think that it'll be better if the
getGateArguments
method inAuthorize
middleware verify if the given model is not already aModel
instance...I can make a PR but as it concerned 3 different branches what's the right way to do ? Create a PR for each version ?
Steps To Reproduce:
I created an extension of the
Authorize
middleware like this which failed recognizing the model :The text was updated successfully, but these errors were encountered: