Fix API input/request variables

This commit is contained in:
grandeljay 2022-11-28 12:13:53 +01:00
parent 9bcf34685b
commit 35f5a76dfa
2 changed files with 3 additions and 3 deletions

View file

@ -259,7 +259,7 @@ switch ($_SERVER['REQUEST_METHOD']) {
break; break;
case 'PUT': case 'PUT':
parse_str(file_get_contents('php://input'), $_PUT); $_PUT = $this->input;
if (isset($_PUT['wish_id'], $_PUT['wish_status'])) { if (isset($_PUT['wish_id'], $_PUT['wish_status'])) {
/** /**

View file

@ -152,7 +152,7 @@ switch ($_SERVER['REQUEST_METHOD']) {
break; break;
case 'PUT': case 'PUT':
parse_str(file_get_contents('php://input'), $_PUT); $_PUT = $this->input;
$database $database
->query( ->query(
@ -165,7 +165,7 @@ switch ($_SERVER['REQUEST_METHOD']) {
break; break;
case 'DELETE': case 'DELETE':
parse_str(file_get_contents('php://input'), $_DELETE); $_DELETE = $this->input;
$database->query( $database->query(
'DELETE FROM `wishlists` 'DELETE FROM `wishlists`