Software /
code /
prosody
Diff
net/http/server.lua @ 10396:3278f2a31a0a
net.http.server: Treat promise rejection without value as a HTTP 500 error
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Tue, 05 Nov 2019 01:34:13 +0100 |
parent | 10395:faa4fcc78b14 |
child | 10501:e8186aba1583 |
line wrap: on
line diff
--- a/net/http/server.lua Fri Nov 01 22:31:15 2019 +0100 +++ b/net/http/server.lua Tue Nov 05 01:34:13 2019 +0100 @@ -196,7 +196,7 @@ result:next(function (ret) handle_result(request, response, ret); end, function (err) - handle_result(request, response, err); + handle_result(request, response, err or 500); end); return true; elseif result_type == "table" then