How to get the below password mesage in catch block laravel
#messages: Illuminate\Support\MessageBag {#1495
#messages: array:1 [
"password" => array:1 [
0 => "The password confirmation does not match."
]
]
CodePudding user response:
I just did it and it works in the catch block
$message = $e->validator->errors()->first('password');