How to use the HTTPVersionNotSupported function from http-errors

Find comprehensive JavaScript http-errors.HTTPVersionNotSupported code examples handpicked from public code repositorys.

154
155
156
157
158
159
160
161
162
163
gatewayTimeout: function gatewayTimeout (message) {
  return new createError.GatewayTimeout(message)
},

httpVersionNotSupported: function httpVersionNotSupported (message) {
  return new createError.HTTPVersionNotSupported(message)
},

variantAlsoNegotiates: function variantAlsoNegotiates (message) {
  return new createError.VariantAlsoNegotiates(message)
fork icon30
star icon340
watch icon17

+ 55 other calls in file

174
175
176
177
178
179
180
181
182
183
module.exports.InternalServerError = new HTTPErrors.InternalServerError()
module.exports.NotImplemented = new HTTPErrors.NotImplemented()
module.exports.BadGateway = new HTTPErrors.BadGateway()
module.exports.ServiceUnavailable = new HTTPErrors.ServiceUnavailable()
module.exports.GatewayTimeout = new HTTPErrors.GatewayTimeout()
module.exports.HTTPVersionNotSupported = new HTTPErrors.HTTPVersionNotSupported()
module.exports.VariantAlsoNegotiates = new HTTPErrors.VariantAlsoNegotiates()
module.exports.InsufficientStorage = new HTTPErrors.InsufficientStorage()
module.exports.LoopDetected = new HTTPErrors.LoopDetected()
module.exports.BandwidthLimitExceeded = new HTTPErrors.BandwidthLimitExceeded()
fork icon1
star icon0
watch icon7

+ 41 other calls in file

177
178
179
180
181
182
183
184
185
186
case 504: {
  httpError = createError.GatewayTimeout();
  break;
}
case 505: {
  httpError = createError.HTTPVersionNotSupported();
  break;
}
case 506: {
  httpError = createError.VariantAlsoNegotiates();
fork icon0
star icon0
watch icon2

+ 41 other calls in file