Software /
code /
prosody
Changeset
11225:8c17c08d100e
net.http.errors: Add error class for DNS resolution failures (thanks SouL)
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Fri, 11 Dec 2020 10:15:30 +0000 |
parents | 11224:8143fd2f138b |
children | 11227:d36e44d00ef8 |
files | net/http/errors.lua |
diffstat | 1 files changed, 4 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/net/http/errors.lua Wed Dec 09 14:51:40 2020 +0000 +++ b/net/http/errors.lua Fri Dec 11 10:15:30 2020 +0000 @@ -40,6 +40,10 @@ code = 0, type = "modify", condition = "bad-request"; text = "Invalid URL"; }; + ["unable to resolve service"] = { + code = 0, type = "cancel", condition = "remote-server-not-found"; + text = "DNS resolution failed"; + }; -- This doesn't attempt to map every single HTTP code (not all have sane mappings), -- but all the common ones should be covered. XEP-0086 was used as reference for