X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/0dd10c3fff9896ca23b884a7ec7a97002065d083..65ea0efe68fb52d0f591c964215866c9175adb6a:/lib/init-website.php?ds=inline diff --git a/lib/init-website.php b/lib/init-website.php index 94dba6f4..bcf3ebf7 100644 --- a/lib/init-website.php +++ b/lib/init-website.php @@ -5,7 +5,10 @@ { header("Access-Control-Allow-Origin: *"); header("Access-Control-Allow-Methods: OPTIONS,GET"); - header("Access-Control-Allow-Headers: ".$_SERVER['HTTP_ACCESS_CONTROL_REQUEST_HEADERS']); + if (!empty($_SERVER['HTTP_ACCESS_CONTROL_REQUEST_HEADERS'])) + { + header("Access-Control-Allow-Headers: ".$_SERVER['HTTP_ACCESS_CONTROL_REQUEST_HEADERS']); + } } if ($_SERVER['REQUEST_METHOD'] == 'OPTIONS') exit;