You could probably simplify it by using getDirty method to get list of changed attributes. And, optionally, move password check to validation in UserEditRequest
.
Xum said:
You could probably simplify it by using getDirty method to get list of changed attributes. And, optionally, move password check to validation in
UserEditRequest
.
How would I go about validating a password in the validation method?
you could split up the statements in to more manageable functions and call them one by one. obviously you will need to do the same tasks from the different controller function in the future. and there's too much extra line feeds in your code. i dont see why you need them.
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community