Mercurial > prosody-hg
comparison net/http/errors.lua @ 12974:ba409c67353b
net: Prefix module imports with prosody namespace
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Fri, 17 Mar 2023 16:23:12 +0100 |
| parents | 8c17c08d100e |
| children |
comparison
equal
deleted
inserted
replaced
| 12973:cc215923297f | 12974:ba409c67353b |
|---|---|
| 1 -- This module returns a table that is suitable for use as a util.error registry, | 1 -- This module returns a table that is suitable for use as a util.error registry, |
| 2 -- and a function to return a util.error object given callback 'code' and 'body' | 2 -- and a function to return a util.error object given callback 'code' and 'body' |
| 3 -- parameters. | 3 -- parameters. |
| 4 | 4 |
| 5 local codes = require "net.http.codes"; | 5 local codes = require "prosody.net.http.codes"; |
| 6 local util_error = require "util.error"; | 6 local util_error = require "prosody.util.error"; |
| 7 | 7 |
| 8 local error_templates = { | 8 local error_templates = { |
| 9 -- This code is used by us to report a client-side or connection error. | 9 -- This code is used by us to report a client-side or connection error. |
| 10 -- Instead of using the code, use the supplied body text to get one of | 10 -- Instead of using the code, use the supplied body text to get one of |
| 11 -- the more detailed errors below. | 11 -- the more detailed errors below. |
