diff --git a/nginx.conf.sigil b/nginx.conf.sigil index 3c388c9..91a3000 100644 --- a/nginx.conf.sigil +++ b/nginx.conf.sigil @@ -15,7 +15,7 @@ gzip_vary on; gzip_comp_level 6;" }} # CORS headers based on request methods -{{ $cors_headers_options := " +{{ $cors_headers_options := ' if ($request_method = 'OPTIONS') { add_header 'Access-Control-Allow-Origin' '$allow_origin' always; add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS'; @@ -25,7 +25,7 @@ if ($request_method = 'OPTIONS') { add_header 'Content-Type' 'text/plain; charset=utf-8'; add_header 'Content-Length' 0; return 204; -}" }} +}' }} {{ $cors_headers_post := " if ($request_method = 'POST') {