cleanup, error pages
This commit is contained in:
@@ -112,6 +112,10 @@ bool render_wasm_error_page(Request& request, String config_key, s32 status_code
|
||||
request.call.remove("error");
|
||||
return(false);
|
||||
}
|
||||
// Rendering the error-page unit set the response to its own (200) status;
|
||||
// re-assert the error status + html content-type so the client sees e.g. 500.
|
||||
request.set_status(status_code, status_reason);
|
||||
request.header["Content-Type"] = first(request.server->config["CONTENT_TYPE"], "text/html; charset=utf-8");
|
||||
print(html);
|
||||
return(true);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user