# HG changeset patch # User Matthew Wild # Date 1601306501 -3600 # Node ID dd1713862c204545351a58da8dba673a755643bf # Parent 1ea3574b19c875f906ef2b2fc68a7d28e9f00e64 net.http.server: Default to HTTP result code 500 when promise is rejected diff -r 1ea3574b19c8 -r dd1713862c20 net/http/server.lua --- a/net/http/server.lua Mon Sep 28 01:55:35 2020 +0200 +++ b/net/http/server.lua Mon Sep 28 16:21:41 2020 +0100 @@ -197,6 +197,7 @@ result:next(function (ret) handle_result(request, response, ret); end, function (err) + response.status_code = 500; handle_result(request, response, err or 500); end); return true;