Commented out extra headers
This commit is contained in:
@@ -28,13 +28,13 @@ $endpoints = array(
|
|||||||
'userstask' => array('POST'),
|
'userstask' => array('POST'),
|
||||||
'createtask' => array('POST')
|
'createtask' => array('POST')
|
||||||
);
|
);
|
||||||
|
/*
|
||||||
header("Access-Control-Allow-Origin: *");
|
header("Access-Control-Allow-Origin: *");
|
||||||
header("Access-Control-Expose-Headers: Access-Control-Allow-Origin");
|
header("Access-Control-Expose-Headers: Access-Control-Allow-Origin");
|
||||||
header("Access-Control-Allow-Headers: Cache-Control, Pragma, Origin, Authorization, Content-Type, X-Requested-With");
|
header("Access-Control-Allow-Headers: Cache-Control, Pragma, Origin, Authorization, Content-Type, X-Requested-With");
|
||||||
header("Access-Control-Allow-Methods: POST, GET, PUT, DELETE, OPTIONS");
|
header("Access-Control-Allow-Methods: POST, GET, PUT, DELETE, OPTIONS");
|
||||||
header('Content-type: application/json');
|
header('Content-type: application/json');
|
||||||
|
*/
|
||||||
$endpoint = strtolower(str_replace('/api/users/', '', strtok($_SERVER['REQUEST_URI'], '?')));
|
$endpoint = strtolower(str_replace('/api/users/', '', strtok($_SERVER['REQUEST_URI'], '?')));
|
||||||
|
|
||||||
if (!isset($endpoints[$endpoint])) {
|
if (!isset($endpoints[$endpoint])) {
|
||||||
|
|||||||
Reference in New Issue
Block a user