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 use form requests all over my app, and use $request->validated() to only use the validated data from the request.
sometimes I have keys that are optional, and I don't want to attach a rule to them, so I simply define them with a rule as an empty string. this used to work just fine.
if I try to use any package, composer updates this function to a new behavior.
I have used this function over 150+ times in my app, what can I do to fix this !! (without refactoring the code)
I'm unable to use packages anymore.
Steps To Reproduce:
make a form request.
add rules like this : 'type' => '' , 'type2'=>'required|nullable'
go to your controller and simply retrieve $request->validated() , only type2 will appear .
This discussion was converted from issue #39348 on October 25, 2021 08:21.
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Description:
I use form requests all over my app, and use $request->validated() to only use the validated data from the request.
sometimes I have keys that are optional, and I don't want to attach a rule to them, so I simply define them with a rule as an empty string. this used to work just fine.
if I try to use any package, composer updates this function to a new behavior.
I have used this function over 150+ times in my app, what can I do to fix this !! (without refactoring the code)
I'm unable to use packages anymore.
Steps To Reproduce:
Beta Was this translation helpful? Give feedback.
All reactions