diff --git a/html/includes/forms/update-config-item.inc.php b/html/includes/forms/update-config-item.inc.php index 2885a2a71..b943fbb5c 100644 --- a/html/includes/forms/update-config-item.inc.php +++ b/html/includes/forms/update-config-item.inc.php @@ -11,9 +11,9 @@ * option) any later version. Please see LICENSE.txt at the top level of * the source code distribution for details. */ -header('Content-type: application/json'); if (is_admin() === false) { + header('Content-type: text/plain'); die('ERROR: You need to be admin'); } @@ -100,4 +100,5 @@ $response = array( 'status' => $status, 'message' => $message, ); +header('Content-type: application/json'); echo _json_encode($response);