mirror of
https://github.com/Relintai/pandemonium_engine.git
synced 2024-11-22 00:48:09 +01:00
Set the status code in WebRoot::_handle_error_send_request().
This commit is contained in:
parent
7476c8608c
commit
db1a38081b
@ -131,6 +131,8 @@ void WebRoot::_handle_request_main(Ref<WebServerRequest> request) {
|
||||
}
|
||||
|
||||
void WebRoot::_handle_error_send_request(Ref<WebServerRequest> request, const int error_code) {
|
||||
request->set_status_code(static_cast<HTTPServerEnums::HTTPStatusCode>(error_code));
|
||||
|
||||
if (error_code == HTTPServerEnums::HTTP_STATUS_CODE_404_NOT_FOUND) {
|
||||
request->compiled_body = "<html><body>404 :(</body></html>";
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user