Answer the question
In order to leave comments, you need to log in
How to get rid of Missing required parameters for [Route: password.reset] [URI: {locale}/password/reset/{token}] error?
The error occurs when trying to reset the password. On the test files of the framework, everything works well. But after changing the routes, an error occurs when trying to reset the password. On the authorization and registration forms, everything is fine.
web.php
Route::group([
'prefix' => '{locale}',
'where' => ['locale' => '[a-zA-Z]{2}'],
'middleware' => 'setlocale'
], function () {
Route::get('/', function () {
return view('index');
});
Auth::routes();
});
Illuminate\Routing\Exceptions\UrlGenerationException
Missing required parameters for [Route: password.reset] [URI: {locale}/password/reset/{token}].
Answer the question
In order to leave comments, you need to log in
Because a new locale variable is added to all auth routes; it must be passed as the first argument in all routes, otherwise there will be errors. In this case, in the ResetPassword notification in the line
Nothing can be changed in the vendor. You need your own files and methods, how to do it in Google there is a lot of material.
You need to go through all the routes, search for the name of the route (for example, here 'password.reset') and add the locale as the first argument.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question