Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to prepare route [api/user] for serialization. Uses Closure. #14

Open
ashishbhoi opened this issue Sep 22, 2018 · 0 comments
Open
Assignees
Labels
bug Something isn't working

Comments

@ashishbhoi
Copy link
Owner

ashishbhoi commented Sep 22, 2018

Route cache cleared!

LogicException : Unable to prepare route [api/user] for serialization. Uses Closure.

at D:\Line Awsome\laravel\lsapp\vendor\laravel\framework\src\Illuminate\Routing\Route.php:880
876| */
877| public function prepareForSerialization()
878| {
879| if ($this->action['uses'] instanceof Closure) {
-> 880| throw new LogicException("Unable to prepare route [{$this->uri}] for serialization. Uses Closure.");
881| }
882|
883| $this->compileRoute();
884|

Exception trace:

1 Illuminate\Routing\Route::prepareForSerialization()
D:\Line Awsome\laravel\lsapp\vendor\laravel\framework\src\Illuminate\Foundation\Console\RouteCacheCommand.php:62

2 Illuminate\Foundation\Console\RouteCacheCommand::handle()
D:\Line Awsome\laravel\lsapp\vendor\laravel\framework\src\Illuminate\Container\BoundMethod.php:29

3 call_user_func_array([])
D:\Line Awsome\laravel\lsapp\vendor\laravel\framework\src\Illuminate\Container\BoundMethod.php:29

4 Illuminate\Container\BoundMethod::Illuminate\Container{closure}()
D:\Line Awsome\laravel\lsapp\vendor\laravel\framework\src\Illuminate\Container\BoundMethod.php:87

5 Illuminate\Container\BoundMethod::callBoundMethod(Object(Illuminate\Foundation\Application), Object(Closure))
D:\Line Awsome\laravel\lsapp\vendor\laravel\framework\src\Illuminate\Container\BoundMethod.php:31

6 Illuminate\Container\BoundMethod::call(Object(Illuminate\Foundation\Application), [])
D:\Line Awsome\laravel\lsapp\vendor\laravel\framework\src\Illuminate\Container\Container.php:564

7 Illuminate\Container\Container::call()
D:\Line Awsome\laravel\lsapp\vendor\laravel\framework\src\Illuminate\Console\Command.php:183

8 Illuminate\Console\Command::execute(Object(Symfony\Component\Console\Input\ArgvInput), Object(Illuminate\Console\OutputStyle))
D:\Line Awsome\laravel\lsapp\vendor\symfony\console\Command\Command.php:251

9 Symfony\Component\Console\Command\Command::run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Illuminate\Console\OutputStyle))
D:\Line Awsome\laravel\lsapp\vendor\laravel\framework\src\Illuminate\Console\Command.php:170

10 Illuminate\Console\Command::run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
D:\Line Awsome\laravel\lsapp\vendor\symfony\console\Application.php:886

11 Symfony\Component\Console\Application::doRunCommand(Object(Illuminate\Foundation\Console\RouteCacheCommand), Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\C
onsole\Output\ConsoleOutput))
D:\Line Awsome\laravel\lsapp\vendor\symfony\console\Application.php:262

12 Symfony\Component\Console\Application::doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
D:\Line Awsome\laravel\lsapp\vendor\symfony\console\Application.php:145

13 Symfony\Component\Console\Application::run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
D:\Line Awsome\laravel\lsapp\vendor\laravel\framework\src\Illuminate\Console\Application.php:89

14 Illuminate\Console\Application::run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
D:\Line Awsome\laravel\lsapp\vendor\laravel\framework\src\Illuminate\Foundation\Console\Kernel.php:122

15 Illuminate\Foundation\Console\Kernel::handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
D:\Line Awsome\laravel\lsapp\artisan:37

@ashishbhoi ashishbhoi self-assigned this Sep 22, 2018
@ashishbhoi ashishbhoi added the bug Something isn't working label Sep 22, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant