mirror of
https://github.com/bjc/prosody.git
synced 2025-04-03 21:27:38 +03:00
mod_http_errors: Set status code 200 from root page
It isn't quite an error.
This commit is contained in:
parent
b24d7fe90d
commit
4439ef50e4
1 changed files with 1 additions and 0 deletions
|
@ -98,6 +98,7 @@ local icon = [[
|
|||
module:hook_object_event(server, "http-error", function (event)
|
||||
local request, response = event.request, event.response;
|
||||
if request and response and request.path == "/" and response.status_code == 404 then
|
||||
response.status_code = 200;
|
||||
response.headers.content_type = "text/html; charset=utf-8";
|
||||
local message = messages["/"];
|
||||
return render(html, {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue