bug fixing
This commit is contained in:
parent
2fdad33a40
commit
12f49e2362
@ -18,11 +18,7 @@ class RestController extends Controller
|
|||||||
public function behaviors()
|
public function behaviors()
|
||||||
{
|
{
|
||||||
$behaviors = parent::behaviors();
|
$behaviors = parent::behaviors();
|
||||||
$behaviors['authenticator'] = [
|
|
||||||
'class' => JwtHttpBearerAuth::class,
|
|
||||||
'auth' => [$this, 'auth'],
|
|
||||||
'optional' => $this->getOptionalActions(),
|
|
||||||
];
|
|
||||||
$behaviors['corsFilter'] = [
|
$behaviors['corsFilter'] = [
|
||||||
'class' => Cors::class,
|
'class' => Cors::class,
|
||||||
'cors' => [
|
'cors' => [
|
||||||
@ -32,6 +28,13 @@ class RestController extends Controller
|
|||||||
'Access-Control-Allow-Credentials' => true,
|
'Access-Control-Allow-Credentials' => true,
|
||||||
]
|
]
|
||||||
];
|
];
|
||||||
|
|
||||||
|
$behaviors['authenticator'] = [
|
||||||
|
'class' => JwtHttpBearerAuth::class,
|
||||||
|
'auth' => [$this, 'auth'],
|
||||||
|
'optional' => $this->getOptionalActions(),
|
||||||
|
];
|
||||||
|
|
||||||
return $behaviors;
|
return $behaviors;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user