How to use the UnavailableForLegalReasons function from http-errors
Find comprehensive JavaScript http-errors.UnavailableForLegalReasons code examples handpicked from public code repositorys.
127 128 129 130 131 132 133 134 135 136
requestHeaderFieldsTooLarge: function requestHeaderFieldsTooLarge (message) { return new createError.RequestHeaderFieldsTooLarge(message) }, unavailableForLegalReasons: function unavailableForLegalReasons (message) { return new createError.UnavailableForLegalReasons(message) }, internalServerError: function internalServerError (message) { const error = new createError.InternalServerError(message)
30
340
17
+ 55 other calls in file
168 169 170 171 172 173 174 175 176 177
module.exports.UnorderedCollection = new HTTPErrors.UnorderedCollection() module.exports.UpgradeRequired = new HTTPErrors.UpgradeRequired() module.exports.PreconditionRequired = new HTTPErrors.PreconditionRequired() module.exports.TooManyRequests = new HTTPErrors.TooManyRequests() module.exports.RequestHeaderFieldsTooLarge = new HTTPErrors.RequestHeaderFieldsTooLarge() module.exports.UnavailableForLegalReasons = new HTTPErrors.UnavailableForLegalReasons() module.exports.InternalServerError = new HTTPErrors.InternalServerError() module.exports.NotImplemented = new HTTPErrors.NotImplemented() module.exports.BadGateway = new HTTPErrors.BadGateway() module.exports.ServiceUnavailable = new HTTPErrors.ServiceUnavailable()
1
0
7
+ 41 other calls in file
157 158 159 160 161 162 163 164 165 166
case 431: { httpError = createError.RequestHeaderFieldsTooLarge(); break; } case 451: { httpError = createError.UnavailableForLegalReasons(); break; } case 501: { httpError = createError.NotImplemented();
0
0
2
+ 41 other calls in file
http-errors.NotFound is the most popular function in http-errors (1819 examples)