2015-12-30 04:14:47 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App;
|
|
|
|
|
|
|
|
use Illuminate\Http\Request;
|
|
|
|
use Tymon\JWTAuth\JWTAuth as BaseJWTAuth;
|
|
|
|
use Tymon\JWTAuth\JWTManager;
|
|
|
|
use Tymon\JWTAuth\Providers\Auth\AuthInterface;
|
|
|
|
use Tymon\JWTAuth\Providers\User\UserInterface;
|
|
|
|
|
|
|
|
class JWTAuth extends BaseJWTAuth
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* {@inheritdoc}
|
|
|
|
*/
|
|
|
|
public function __construct(JWTManager $manager, UserInterface $user, AuthInterface $auth, Request $request)
|
|
|
|
{
|
2017-02-14 06:53:02 +00:00
|
|
|
parent::__construct($manager, $user, $auth, $request);
|
2015-12-30 04:14:47 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* {@inheritdoc}
|
|
|
|
*/
|
2018-08-24 15:27:19 +00:00
|
|
|
public function parseToken($method = 'bearer', $header = 'authorization', $query = 'jwt-token'): BaseJWTAuth
|
2015-12-30 04:14:47 +00:00
|
|
|
{
|
|
|
|
return parent::parseToken($method, $header, $query);
|
|
|
|
}
|
|
|
|
}
|