bug fixing

This commit is contained in:
Roland Schneider
2021-09-28 20:53:50 +02:00
parent e6f8660d78
commit 6cd7af5fd0
2 changed files with 3 additions and 29 deletions

View File

@@ -18,23 +18,12 @@ use yii\web\UnauthorizedHttpException;
/** @noinspection PhpUnused */
class LoginController extends Controller
class LoginController extends RestController
{
public function behaviors()
protected function getOptionalActions()
{
$behaviors = parent::behaviors();
$behaviors['corsFilter'] = [
'class' => CorsCustom::class,
'cors' => [
// restrict access to
'Origin' => ['https://botondfitness.hu'],
// Allow credentials (cookies, authorization headers, etc.) to be exposed to the browser
'Access-Control-Allow-Credentials' => true,
]
];
return $behaviors;
return ['login'];
}
/**