Software /
code /
prosody
Diff
net/http/server.lua @ 10952:05d218aae3d1
Merge 0.11->trunk
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Tue, 23 Jun 2020 17:59:24 +0200 |
parent | 10719:977c9883f625 |
parent | 10951:f4215f8baa5d |
child | 11096:dd1713862c20 |
line wrap: on
line diff
--- a/net/http/server.lua Tue Jun 23 16:50:26 2020 +0100 +++ b/net/http/server.lua Tue Jun 23 17:59:24 2020 +0200 @@ -254,7 +254,8 @@ }; conn._http_open_response = response; - local host = (request.headers.host or ""):match("[^:]+"); + local host = request.headers.host; + if host then host = host:gsub(":%d+$",""); end -- Some sanity checking local err_code, err;