Hey guys,
I tried to implement JWT into Lumen, but I got the following error after request a route that requires jwt.auth:
BindingResolutionException in Container.php line 752: Target [Illuminate\Contracts\Routing\ResponseFactory] is not instantiable while building [Tymon\JWTAuth\Middleware\GetUserFromToken].
I've found https://github.com/tymondesigns/jwt-auth/pull/532 it seemed the same issue, but even if I added the code it has suggested, it still not works.
Is this an issue of the plugin, or am I missing something that causes this problem?:)
Thanks in advance
I've found the solution. The AppServiceProvider is not used by default, so it should be uncommented:)
After that I had an other error, but it can be solved by https://github.com/tymondesigns/jwt-auth/issues/564
I need help
please help me!!
use Illuminate\Http\Request;
add provider in the config/app.php
'providers' => [
/*
* Laravel Framework Service Providers...
*/
Illuminate\Auth\AuthServiceProvider::class,
Tymon\JWTAuth\Providers\JWTAuthServiceProvider::class,
...