From 34c7e11d84059136ac8f526a6e179b29e62c6025 Mon Sep 17 00:00:00 2001 From: wn_ Date: Mon, 2 Jun 2025 20:57:31 +0000 Subject: Use the official JSON MIME type of 'application/json'. --- public.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'public.php') diff --git a/public.php b/public.php index 5d99fe519..68327c2d7 100644 --- a/public.php +++ b/public.php @@ -34,7 +34,7 @@ if (str_starts_with($method, "_")) { user_error("Refusing to invoke method $method which starts with underscore.", E_USER_WARNING); - header("Content-Type: text/json"); + header("Content-Type: application/json"); print Errors::to_json(Errors::E_UNAUTHORIZED); return; @@ -49,7 +49,7 @@ $handler->$method(); } else { user_error("Refusing to invoke method $method which has required parameters.", E_USER_WARNING); - header("Content-Type: text/json"); + header("Content-Type: application/json"); print Errors::to_json(Errors::E_UNAUTHORIZED); } -- cgit v1.2.3-54-g00ecf