I’m new to Laravel 10, and I recently installed Jetstream. When I run php artisan route:list
in the console, I get the following error: Class "verified" does not exist
.
I do have verified
in my Kernel:
protected $middlewareAliases = [
...
...
'verified' => IlluminateAuthMiddlewareEnsureEmailIsVerified::class,
];
I don’t know what I’m missing or how to fix this.
2
Answers
$middlewareAliases
is NOT a class alias. You can do that withaliases
in theapp.php
file$middlewareAliases
is used for routesVerified
middleware is correctly assigned in your routes.