bug fixing

This commit is contained in:
Roland Schneider
2021-09-28 19:48:07 +02:00
parent ae1640c444
commit f9c845f722
2 changed files with 15 additions and 15 deletions

View File

@@ -11,14 +11,14 @@ class CorsCustom extends Cors
public function beforeAction($action){
parent::beforeAction($action);
$result = parent::beforeAction($action);
if (Yii::$app->getRequest()->getMethod() === 'OPTIONS') {
// Yii::$app->getResponse()->getHeaders()->set('Allow', 'POST GET PUT');
Yii::$app->getResponse()->getHeaders()->set('Allow', 'POST GET PUT');
Yii::$app->end();
}
return true;
return $result;
}