From b63bd7005be37350241ee92dbb22160f028de4e8 Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Sun, 20 Jul 2025 12:52:05 +0100 Subject: [PATCH] Send export errors in plain text --- cookbooks/tile/templates/default/export.erb | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/cookbooks/tile/templates/default/export.erb b/cookbooks/tile/templates/default/export.erb index 4b524925d..bb3780cfc 100644 --- a/cookbooks/tile/templates/default/export.erb +++ b/cookbooks/tile/templates/default/export.erb @@ -49,16 +49,8 @@ def bytesio_size(bio): # Routine to report an error def output_error(message, status = "400 Bad Request"): print("Status: %s" % status) - output_headers("text/html") - print("") - print("") - print("Error") - print("") - print("") - print("

Error

") - print("

%s

" % message) - print("") - print("") + output_headers("text/plain") + print(message) # Add a copyright notice for raster formats (PNG, JPEG, WEBP) def add_copyright_notice_raster(image, map_width, map_height, format): -- 2.39.5