And if I run php artisan config:clear , php artisan route:clear I still get the error.
Jul 31, 2020
12
Level 1
Unable to prepare route [logout] for serialization.
Hi
I can't run php artisan route:cache. I moved all my closures into controllers, but when I run the command I get the following error:
php artisan route:cache
Route cache cleared!
LogicException
Unable to prepare route [logout] for serialization. Another route has already been assigned name [logout].
at vendor/laravel/framework/src/Illuminate/Routing/AbstractRouteCollection.php:212
208| $route->name($name = $this->generateRouteName());
209|
210| $this->add($route);
211| } elseif (! is_null($symfonyRoutes->get($name))) {
> 212| throw new LogicException("Unable to prepare route [{$route->uri}] for serialization. Another route has already been assigned name [{$name}].");
213| }
214|
215| $symfonyRoutes->add($route->getName(), $route->toSymfonyRoute());
216|
+20 vendor frames
21 artisan:37
Illuminate\Foundation\Console\Kernel::handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
When I run php artisan route:list I don't have any web or api routes with clojure actions.
Does anyone have a clue to fix this error? I have been banging my head against the wall and i'm at complete standstill.
After I got this error I can't consume my api anymore I get a error 401 Unauthorized.
Please or to participate in this conversation.