diff --git a/badgateway.go b/badgateway.go index 344ace9..f049cbe 100644 --- a/badgateway.go +++ b/badgateway.go @@ -8,7 +8,9 @@ var _ Error = internalBadGateway{} var _ ServerError = internalBadGateway{} var _ BadGateway = internalBadGateway{} -var ErrBadGateway error = BadGatewayWrap(nil) +var ServerErrorBadGateway ServerError = BadGatewayWrap(nil).(BadGateway) +var ErrHTTPBadGateway Error = ServerErrorBadGateway +var ErrBadGateway error = ServerErrorBadGateway type BadGateway interface { ServerError diff --git a/badrequest.go b/badrequest.go index 3345f46..b29d706 100644 --- a/badrequest.go +++ b/badrequest.go @@ -8,7 +8,9 @@ var _ Error = internalBadRequest{} var _ ClientError = internalBadRequest{} var _ BadRequest = internalBadRequest{} -var ErrBadRequest error = BadRequestWrap(nil) +var ClientErrorBadRequest ClientError = BadRequestWrap(nil).(BadRequest) +var ErrHTTPBadRequest Error = ClientErrorBadRequest +var ErrBadRequest error = ClientErrorBadRequest type BadRequest interface { ClientError diff --git a/conflict.go b/conflict.go index a631656..07da7b0 100644 --- a/conflict.go +++ b/conflict.go @@ -8,7 +8,9 @@ var _ Error = internalConflict{} var _ ClientError = internalConflict{} var _ Conflict = internalConflict{} -var ErrConflict error = ConflictWrap(nil) +var ClientErrorConflict ClientError = ConflictWrap(nil).(Conflict) +var ErrHTTPConflict Error = ClientErrorConflict +var ErrConflict error = ClientErrorConflict type Conflict interface { ClientError diff --git a/errgone_test.go b/errgone_test.go index 8a1b211..e588913 100644 --- a/errgone_test.go +++ b/errgone_test.go @@ -1,7 +1,5 @@ package errhttp_test -//@TODO: THIS TEST IS GIVING A WEIRD ERROR -/* import ( "testing" @@ -49,4 +47,3 @@ func TestErrGone(t *testing.T) { } } } -*/ diff --git a/expectationfailed.go b/expectationfailed.go index e3dd3f3..c7736ae 100644 --- a/expectationfailed.go +++ b/expectationfailed.go @@ -8,7 +8,9 @@ var _ Error = internalExpectationFailed{} var _ ClientError = internalExpectationFailed{} var _ ExpectationFailed = internalExpectationFailed{} -var ErrExpectationFailed error = ExpectationFailedWrap(nil) +var ClientErrorExpectationFailed ClientError = ExpectationFailedWrap(nil).(ExpectationFailed) +var ErrHTTPExpectationFailed Error = ClientErrorExpectationFailed +var ErrExpectationFailed error = ClientErrorExpectationFailed type ExpectationFailed interface { ClientError diff --git a/faileddependency.go b/faileddependency.go index b8f5677..f88570c 100644 --- a/faileddependency.go +++ b/faileddependency.go @@ -8,7 +8,9 @@ var _ Error = internalFailedDependency{} var _ ClientError = internalFailedDependency{} var _ FailedDependency = internalFailedDependency{} -var ErrFailedDependency error = FailedDependencyWrap(nil) +var ClientErrorFailedDependency ClientError = FailedDependencyWrap(nil).(FailedDependency) +var ErrHTTPFailedDependency Error = ClientErrorFailedDependency +var ErrFailedDependency error = ClientErrorFailedDependency type FailedDependency interface { ClientError diff --git a/forbidden.go b/forbidden.go index 5179dbd..c6bfbda 100644 --- a/forbidden.go +++ b/forbidden.go @@ -8,7 +8,9 @@ var _ Error = internalForbidden{} var _ ClientError = internalForbidden{} var _ Forbidden = internalForbidden{} -var ErrForbidden error = ForbiddenWrap(nil) +var ClientErrorForbidden ClientError = ForbiddenWrap(nil).(Forbidden) +var ErrHTTPForbidden Error = ClientErrorForbidden +var ErrForbidden error = ClientErrorForbidden type Forbidden interface { ClientError diff --git a/gatewaytimeout.go b/gatewaytimeout.go index 2a0802d..de3c131 100644 --- a/gatewaytimeout.go +++ b/gatewaytimeout.go @@ -8,7 +8,9 @@ var _ Error = internalGatewayTimeout{} var _ ServerError = internalGatewayTimeout{} var _ GatewayTimeout = internalGatewayTimeout{} -var ErrGatewayTimeout error = GatewayTimeoutWrap(nil) +var ServerErrorGatewayTimeout ServerError = GatewayTimeoutWrap(nil).(GatewayTimeout) +var ErrHTTPGatewayTimeout Error = ServerErrorGatewayTimeout +var ErrGatewayTimeout error = ServerErrorGatewayTimeout type GatewayTimeout interface { ServerError diff --git a/gone.go b/gone.go index 5e10b6f..9bfb902 100644 --- a/gone.go +++ b/gone.go @@ -8,10 +8,12 @@ var _ Error = internalGone{} var _ ClientError = internalGone{} var _ Gone = internalGone{} -var ErrGone error = GoneWrap(nil) +var ClientErrorGone ClientError = GoneWrap(nil).(Gone) +var ErrHTTPGone Error = ClientErrorGone +var ErrGone error = ClientErrorGone type Gone interface { - ClientError() + ClientError Gone() } diff --git a/httpversionnotsupported.go b/httpversionnotsupported.go index 7030002..3549546 100644 --- a/httpversionnotsupported.go +++ b/httpversionnotsupported.go @@ -8,7 +8,9 @@ var _ Error = internalHTTPVersionNotSupported{} var _ ServerError = internalHTTPVersionNotSupported{} var _ HTTPVersionNotSupported = internalHTTPVersionNotSupported{} -var ErrHTTPVersionNotSupported error = HTTPVersionNotSupportedWrap(nil) +var ServerErrorHTTPVersionNotSupported ServerError = HTTPVersionNotSupportedWrap(nil).(HTTPVersionNotSupported) +var ErrHTTPHTTPVersionNotSupported Error = ServerErrorHTTPVersionNotSupported +var ErrHTTPVersionNotSupported error = ServerErrorHTTPVersionNotSupported type HTTPVersionNotSupported interface { ServerError diff --git a/insufficientstorage.go b/insufficientstorage.go index 9560561..64c1748 100644 --- a/insufficientstorage.go +++ b/insufficientstorage.go @@ -8,7 +8,9 @@ var _ Error = internalInsufficientStorage{} var _ ServerError = internalInsufficientStorage{} var _ InsufficientStorage = internalInsufficientStorage{} -var ErrInsufficientStorage error = InsufficientStorageWrap(nil) +var ServerErrorInsufficientStorage ServerError = InsufficientStorageWrap(nil).(InsufficientStorage) +var ErrHTTPInsufficientStorage Error = ServerErrorInsufficientStorage +var ErrInsufficientStorage error = ServerErrorInsufficientStorage type InsufficientStorage interface { ServerError diff --git a/internalservererror.go b/internalservererror.go index 63a82c5..b1e698c 100644 --- a/internalservererror.go +++ b/internalservererror.go @@ -8,7 +8,9 @@ var _ Error = internalInternalServerError{} var _ ServerError = internalInternalServerError{} var _ InternalServerError = internalInternalServerError{} -var ErrInternalServerError error = InternalServerErrorWrap(nil) +var ServerErrorInternalServerError InternalServerError = InternalServerErrorWrap(nil).(InternalServerError) +var ErrHTTPInternalServerError Error = ServerErrorInternalServerError +var ErrInternalServerError error = ServerErrorInternalServerError type InternalServerError interface { ServerError diff --git a/lengthrequired.go b/lengthrequired.go index 6573fec..701d4ed 100644 --- a/lengthrequired.go +++ b/lengthrequired.go @@ -8,7 +8,9 @@ var _ Error = internalLengthRequired{} var _ ClientError = internalLengthRequired{} var _ LengthRequired = internalLengthRequired{} -var ErrLengthRequired error = LengthRequiredWrap(nil) +var ClientErrorLengthRequired ClientError = LengthRequiredWrap(nil).(LengthRequired) +var ErrHTTPLengthRequired Error = ClientErrorLengthRequired +var ErrLengthRequired error = ClientErrorLengthRequired type LengthRequired interface { ClientError diff --git a/locked.go b/locked.go index 25813ed..293de05 100644 --- a/locked.go +++ b/locked.go @@ -8,7 +8,9 @@ var _ Error = internalLocked{} var _ ClientError = internalLocked{} var _ Locked = internalLocked{} -var ErrLocked error = LockedWrap(nil) +var ClientErrorLocked ClientError = LockedWrap(nil).(Locked) +var ErrHTTPLocked Error = ClientErrorLocked +var ErrLocked error = ClientErrorLocked type Locked interface { ClientError diff --git a/loopdetected.go b/loopdetected.go index e329a99..49c720d 100644 --- a/loopdetected.go +++ b/loopdetected.go @@ -8,7 +8,9 @@ var _ Error = internalLoopDetected{} var _ ServerError = internalLoopDetected{} var _ LoopDetected = internalLoopDetected{} -var ErrLoopDetected error = LoopDetectedWrap(nil) +var ServerErrorLoopDetected ServerError = LoopDetectedWrap(nil).(LoopDetected) +var ErrHTTPLoopDetected Error = ServerErrorLoopDetected +var ErrLoopDetected error = ServerErrorLoopDetected type LoopDetected interface { ServerError diff --git a/methodnotallowed.go b/methodnotallowed.go index 8db85e8..bbda43b 100644 --- a/methodnotallowed.go +++ b/methodnotallowed.go @@ -8,7 +8,9 @@ var _ Error = internalMethodNotAllowed{} var _ ClientError = internalMethodNotAllowed{} var _ MethodNotAllowed = internalMethodNotAllowed{} -var ErrMethodNotAllowed error = MethodNotAllowedWrap(nil) +var ClientErrorMethodNotAllowed ClientError = MethodNotAllowedWrap(nil).(MethodNotAllowed) +var ErrHTTPMethodNotAllowed Error = ClientErrorMethodNotAllowed +var ErrMethodNotAllowed error = ClientErrorMethodNotAllowed type MethodNotAllowed interface { ClientError diff --git a/misdirectedrequest.go b/misdirectedrequest.go index 1cb5ad8..8ded717 100644 --- a/misdirectedrequest.go +++ b/misdirectedrequest.go @@ -8,7 +8,9 @@ var _ Error = internalMisdirectedRequest{} var _ ClientError = internalMisdirectedRequest{} var _ MisdirectedRequest = internalMisdirectedRequest{} -var ErrMisdirectedRequest error = MisdirectedRequestWrap(nil) +var ClientErrorMisdirectedRequest ClientError = MisdirectedRequestWrap(nil).(MisdirectedRequest) +var ErrHTTPMisdirectedRequest Error = ClientErrorMisdirectedRequest +var ErrMisdirectedRequest error = ClientErrorMisdirectedRequest type MisdirectedRequest interface { ClientError diff --git a/networkauthenticationrequired.go b/networkauthenticationrequired.go index bb642cc..396b52e 100644 --- a/networkauthenticationrequired.go +++ b/networkauthenticationrequired.go @@ -8,7 +8,9 @@ var _ Error = internalNetworkAuthenticationRequired{} var _ ServerError = internalNetworkAuthenticationRequired{} var _ NetworkAuthenticationRequired = internalNetworkAuthenticationRequired{} -var ErrNetworkAuthenticationRequired error = NetworkAuthenticationRequiredWrap(nil) +var ServerErrorNetworkAuthenticationRequired ServerError = NetworkAuthenticationRequiredWrap(nil).(NetworkAuthenticationRequired) +var ErrHTTPNetworkAuthenticationRequired Error = ServerErrorNetworkAuthenticationRequired +var ErrNetworkAuthenticationRequired error = ServerErrorNetworkAuthenticationRequired type NetworkAuthenticationRequired interface { ServerError diff --git a/notacceptable.go b/notacceptable.go index f67d4ea..112d93a 100644 --- a/notacceptable.go +++ b/notacceptable.go @@ -8,7 +8,9 @@ var _ Error = internalNotAcceptable{} var _ ClientError = internalNotAcceptable{} var _ NotAcceptable = internalNotAcceptable{} -var ErrNotAcceptable error = NotAcceptableWrap(nil) +var ClientErrorNotAcceptable ClientError = NotAcceptableWrap(nil).(NotAcceptable) +var ErrHTTPNotAcceptable Error = ClientErrorNotAcceptable +var ErrNotAcceptable error = ClientErrorNotAcceptable type NotAcceptable interface { ClientError diff --git a/notextended.go b/notextended.go index c51d9fc..571281c 100644 --- a/notextended.go +++ b/notextended.go @@ -8,7 +8,9 @@ var _ Error = internalNotExtended{} var _ ServerError = internalNotExtended{} var _ NotExtended = internalNotExtended{} -var ErrNotExtended error = NotExtendedWrap(nil) +var ServerErrorNotExtended ServerError = NotExtendedWrap(nil).(NotExtended) +var ErrHTTPNotExtended Error = ServerErrorNotExtended +var ErrNotExtended error = ServerErrorNotExtended type NotExtended interface { ServerError diff --git a/notfound.go b/notfound.go index bf99662..3c698dc 100644 --- a/notfound.go +++ b/notfound.go @@ -8,7 +8,9 @@ var _ Error = internalNotFound{} var _ ClientError = internalNotFound{} var _ NotFound = internalNotFound{} -var ErrNotFound error = NotFoundWrap(nil) +var ClientErrorNotFound ClientError = NotFoundWrap(nil).(NotFound) +var ErrHTTPNotFound Error = ClientErrorNotFound +var ErrNotFound error = ClientErrorNotFound type NotFound interface { ClientError diff --git a/notimplemented.go b/notimplemented.go index f219b74..d440db3 100644 --- a/notimplemented.go +++ b/notimplemented.go @@ -8,7 +8,9 @@ var _ Error = internalNotImplemented{} var _ ServerError = internalNotImplemented{} var _ NotImplemented = internalNotImplemented{} -var ErrNotImplemented error = NotImplementedWrap(nil) +var ServerErrorNotImplemented ServerError = NotImplementedWrap(nil).(NotImplemented) +var ErrHTTPNotImplemented Error = ServerErrorNotImplemented +var ErrNotImplemented error = ServerErrorNotImplemented type NotImplemented interface { ServerError diff --git a/paymentrequired.go b/paymentrequired.go index f38a2f7..00c8f1a 100644 --- a/paymentrequired.go +++ b/paymentrequired.go @@ -8,7 +8,9 @@ var _ Error = internalPaymentRequired{} var _ ClientError = internalPaymentRequired{} var _ PaymentRequired = internalPaymentRequired{} -var ErrPaymentRequired error = PaymentRequiredWrap(nil) +var ClientErrorPaymentRequired ClientError = PaymentRequiredWrap(nil).(PaymentRequired) +var ErrHTTPPaymentRequired Error = ClientErrorPaymentRequired +var ErrPaymentRequired error = ClientErrorPaymentRequired type PaymentRequired interface { ClientError diff --git a/preconditionfailed.go b/preconditionfailed.go index 7267b05..2b92d4b 100644 --- a/preconditionfailed.go +++ b/preconditionfailed.go @@ -8,7 +8,9 @@ var _ Error = internalPreconditionFailed{} var _ ClientError = internalPreconditionFailed{} var _ PreconditionFailed = internalPreconditionFailed{} -var ErrPreconditionFailed error = PreconditionFailedWrap(nil) +var ClientErrorPreconditionFailed ClientError = PreconditionFailedWrap(nil).(PreconditionFailed) +var ErrHTTPPreconditionFailed Error = ClientErrorPreconditionFailed +var ErrPreconditionFailed error = ClientErrorPreconditionFailed type PreconditionFailed interface { ClientError diff --git a/proxyauthrequired.go b/proxyauthrequired.go index ddf57a3..36c3351 100644 --- a/proxyauthrequired.go +++ b/proxyauthrequired.go @@ -8,7 +8,9 @@ var _ Error = internalProxyAuthRequired{} var _ ClientError = internalProxyAuthRequired{} var _ ProxyAuthRequired = internalProxyAuthRequired{} -var ErrProxyAuthRequired error = ProxyAuthRequiredWrap(nil) +var ClientErrorProxyAuthRequired ClientError = ProxyAuthRequiredWrap(nil).(ProxyAuthRequired) +var ErrHTTPProxyAuthRequired Error = ClientErrorProxyAuthRequired +var ErrProxyAuthRequired error = ClientErrorProxyAuthRequired type ProxyAuthRequired interface { ClientError diff --git a/requestedrangenotsatisfiable.go b/requestedrangenotsatisfiable.go index bf7c84a..e78de3b 100644 --- a/requestedrangenotsatisfiable.go +++ b/requestedrangenotsatisfiable.go @@ -8,7 +8,9 @@ var _ Error = internalRequestedRangeNotSatisfiable{} var _ ClientError = internalRequestedRangeNotSatisfiable{} var _ RequestedRangeNotSatisfiable = internalRequestedRangeNotSatisfiable{} -var ErrRequestedRangeNotSatisfiable error = RequestedRangeNotSatisfiableWrap(nil) +var ClientErrorRequestedRangeNotSatisfiable ClientError = RequestedRangeNotSatisfiableWrap(nil).(RequestedRangeNotSatisfiable) +var ErrHTTPRequestedRangeNotSatisfiable Error = ClientErrorRequestedRangeNotSatisfiable +var ErrRequestedRangeNotSatisfiable error = ClientErrorRequestedRangeNotSatisfiable type RequestedRangeNotSatisfiable interface { ClientError diff --git a/requestentitytoolarge.go b/requestentitytoolarge.go index 745fa77..fdf485c 100644 --- a/requestentitytoolarge.go +++ b/requestentitytoolarge.go @@ -8,7 +8,9 @@ var _ Error = internalRequestEntityTooLarge{} var _ ClientError = internalRequestEntityTooLarge{} var _ RequestEntityTooLarge = internalRequestEntityTooLarge{} -var ErrRequestEntityTooLarge error = RequestEntityTooLargeWrap(nil) +var ClientErrorRequestEntityTooLarge ClientError = RequestEntityTooLargeWrap(nil).(RequestEntityTooLarge) +var ErrHTTPRequestEntityTooLarge Error = ClientErrorRequestEntityTooLarge +var ErrRequestEntityTooLarge error = ClientErrorRequestEntityTooLarge type RequestEntityTooLarge interface { ClientError diff --git a/requestheaderfieldstoolarge.go b/requestheaderfieldstoolarge.go index 5443462..0e023e6 100644 --- a/requestheaderfieldstoolarge.go +++ b/requestheaderfieldstoolarge.go @@ -8,7 +8,9 @@ var _ Error = internalRequestHeaderFieldsTooLarge{} var _ ClientError = internalRequestHeaderFieldsTooLarge{} var _ RequestHeaderFieldsTooLarge = internalRequestHeaderFieldsTooLarge{} -var ErrRequestHeaderFieldsTooLarge error = RequestHeaderFieldsTooLargeWrap(nil) +var ClientErrorRequestHeaderFieldsTooLarge ClientError = RequestHeaderFieldsTooLargeWrap(nil).(RequestHeaderFieldsTooLarge) +var ErrHTTPRequestHeaderFieldsTooLarge Error = ClientErrorRequestHeaderFieldsTooLarge +var ErrRequestHeaderFieldsTooLarge error = ClientErrorRequestHeaderFieldsTooLarge type RequestHeaderFieldsTooLarge interface { ClientError diff --git a/requesttimeout.go b/requesttimeout.go index 289f53b..dc85999 100644 --- a/requesttimeout.go +++ b/requesttimeout.go @@ -8,7 +8,9 @@ var _ Error = internalRequestTimeout{} var _ ClientError = internalRequestTimeout{} var _ RequestTimeout = internalRequestTimeout{} -var ErrRequestTimeout error = RequestTimeoutWrap(nil) +var ClientErrorRequestTimeout ClientError = RequestTimeoutWrap(nil).(RequestTimeout) +var ErrHTTPRequestTimeout Error = ClientErrorRequestTimeout +var ErrRequestTimeout error = ClientErrorRequestTimeout type RequestTimeout interface { ClientError diff --git a/requesturitoolong.go b/requesturitoolong.go index 9ea1bfb..a3ea75c 100644 --- a/requesturitoolong.go +++ b/requesturitoolong.go @@ -8,7 +8,9 @@ var _ Error = internalRequestURITooLong{} var _ ClientError = internalRequestURITooLong{} var _ RequestURITooLong = internalRequestURITooLong{} -var ErrRequestURITooLong error = RequestURITooLongWrap(nil) +var ClientErrorRequestURITooLong ClientError = RequestURITooLongWrap(nil).(RequestURITooLong) +var ErrHTTPRequestURITooLong Error = ClientErrorRequestURITooLong +var ErrRequestURITooLong error = ClientErrorRequestURITooLong type RequestURITooLong interface { ClientError diff --git a/serviceunavailable.go b/serviceunavailable.go index e08ef7c..4960bf0 100644 --- a/serviceunavailable.go +++ b/serviceunavailable.go @@ -8,7 +8,9 @@ var _ Error = internalServiceUnavailable{} var _ ServerError = internalServiceUnavailable{} var _ ServiceUnavailable = internalServiceUnavailable{} -var ErrServiceUnavailable error = ServiceUnavailableWrap(nil) +var ServerErrorServiceUnavailable ServerError = ServiceUnavailableWrap(nil).(ServiceUnavailable) +var ErrHTTPServiceUnavailable Error = ServerErrorServiceUnavailable +var ErrServiceUnavailable error = ServerErrorServiceUnavailable type ServiceUnavailable interface { ServerError diff --git a/teapot.go b/teapot.go index 2fa6855..f4b45f5 100644 --- a/teapot.go +++ b/teapot.go @@ -8,7 +8,9 @@ var _ Error = internalTeapot{} var _ ClientError = internalTeapot{} var _ Teapot = internalTeapot{} -var ErrTeapot error = TeapotWrap(nil) +var ClientErrorTeapot ClientError = TeapotWrap(nil).(Teapot) +var ErrHTTPTeapot Error = ClientErrorTeapot +var ErrTeapot error = ClientErrorTeapot type Teapot interface { ClientError diff --git a/tooearly.go b/tooearly.go index 67a8a7b..653c1fa 100644 --- a/tooearly.go +++ b/tooearly.go @@ -8,7 +8,9 @@ var _ Error = internalTooEarly{} var _ ClientError = internalTooEarly{} var _ TooEarly = internalTooEarly{} -var ErrTooEarly error = TooEarlyWrap(nil) +var ClientErrorTooEarly ClientError = TooEarlyWrap(nil).(TooEarly) +var ErrHTTPTooEarly Error = ClientErrorTooEarly +var ErrTooEarly error = ClientErrorTooEarly type TooEarly interface { ClientError diff --git a/toomanyrequests.go b/toomanyrequests.go index aea99ae..fb3b7cc 100644 --- a/toomanyrequests.go +++ b/toomanyrequests.go @@ -8,7 +8,9 @@ var _ Error = internalTooManyRequests{} var _ ClientError = internalTooManyRequests{} var _ TooManyRequests = internalTooManyRequests{} -var ErrTooManyRequests error = TooManyRequestsWrap(nil) +var ClientErrorTooManyRequests ClientError = TooManyRequestsWrap(nil).(TooManyRequests) +var ErrHTTPTooManyRequests Error = ClientErrorTooManyRequests +var ErrTooManyRequests error = ClientErrorTooManyRequests type TooManyRequests interface { ClientError diff --git a/unauthorized.go b/unauthorized.go index 997bfd8..1fb9870 100644 --- a/unauthorized.go +++ b/unauthorized.go @@ -8,7 +8,9 @@ var _ Error = internalUnauthorized{} var _ ClientError = internalUnauthorized{} var _ Unauthorized = internalUnauthorized{} -var ErrUnauthorized error = UnauthorizedWrap(nil) +var ClientErrorUnauthorized ClientError = UnauthorizedWrap(nil).(Unauthorized) +var ErrHTTPUnauthorized Error = ClientErrorUnauthorized +var ErrUnauthorized error = ClientErrorUnauthorized type Unauthorized interface { ClientError diff --git a/unavailableforlegalreasons.go b/unavailableforlegalreasons.go index cd388b1..b090c3e 100644 --- a/unavailableforlegalreasons.go +++ b/unavailableforlegalreasons.go @@ -8,7 +8,9 @@ var _ Error = internalUnavailableForLegalReasons{} var _ ClientError = internalUnavailableForLegalReasons{} var _ UnavailableForLegalReasons = internalUnavailableForLegalReasons{} -var ErrUnavailableForLegalReasons error = UnavailableForLegalReasonsWrap(nil) +var ClientErrorUnavailableForLegalReasons ClientError = UnavailableForLegalReasonsWrap(nil).(UnavailableForLegalReasons) +var ErrHTTPUnavailableForLegalReasons Error = ClientErrorUnavailableForLegalReasons +var ErrUnavailableForLegalReasons error = ClientErrorUnavailableForLegalReasons type UnavailableForLegalReasons interface { ClientError diff --git a/unprocessableentity.go b/unprocessableentity.go index 71670b3..bfe6ceb 100644 --- a/unprocessableentity.go +++ b/unprocessableentity.go @@ -8,7 +8,9 @@ var _ Error = internalUnprocessableEntity{} var _ ClientError = internalUnprocessableEntity{} var _ UnprocessableEntity = internalUnprocessableEntity{} -var ErrUnprocessableEntity error = UnprocessableEntityWrap(nil) +var ClientErrorUnprocessableEntity ClientError = UnprocessableEntityWrap(nil).(UnprocessableEntity) +var ErrHTTPUnprocessableEntity Error = ClientErrorUnprocessableEntity +var ErrUnprocessableEntity error = ClientErrorUnprocessableEntity type UnprocessableEntity interface { ClientError diff --git a/unsupportedmediatype.go b/unsupportedmediatype.go index ec7d99b..43ca336 100644 --- a/unsupportedmediatype.go +++ b/unsupportedmediatype.go @@ -8,7 +8,9 @@ var _ Error = internalUnsupportedMediaType{} var _ ClientError = internalUnsupportedMediaType{} var _ UnsupportedMediaType = internalUnsupportedMediaType{} -var ErrUnsupportedMediaType error = UnsupportedMediaTypeWrap(nil) +var ClientErrorUnsupportedMediaType ClientError = UnsupportedMediaTypeWrap(nil).(UnsupportedMediaType) +var ErrHTTPUnsupportedMediaType Error = ClientErrorUnsupportedMediaType +var ErrUnsupportedMediaType error = ClientErrorUnsupportedMediaType type UnsupportedMediaType interface { ClientError diff --git a/upgraderequired.go b/upgraderequired.go index 557b39b..ac76b35 100644 --- a/upgraderequired.go +++ b/upgraderequired.go @@ -8,7 +8,9 @@ var _ Error = internalUpgradeRequired{} var _ ClientError = internalUpgradeRequired{} var _ UpgradeRequired = internalUpgradeRequired{} -var ErrUpgradeRequired error = UpgradeRequiredWrap(nil) +var ClientErrorUpgradeRequired ClientError = UpgradeRequiredWrap(nil).(UpgradeRequired) +var ErrHTTPUpgradeRequired Error = ClientErrorUpgradeRequired +var ErrUpgradeRequired error = ClientErrorUpgradeRequired type UpgradeRequired interface { ClientError diff --git a/variantalsonegotiates.go b/variantalsonegotiates.go index 66ba564..07b49c7 100644 --- a/variantalsonegotiates.go +++ b/variantalsonegotiates.go @@ -8,7 +8,9 @@ var _ Error = internalVariantAlsoNegotiates{} var _ ServerError = internalVariantAlsoNegotiates{} var _ VariantAlsoNegotiates = internalVariantAlsoNegotiates{} -var ErrVariantAlsoNegotiates error = VariantAlsoNegotiatesWrap(nil) +var ServerErrorVariantAlsoNegotiates ServerError = VariantAlsoNegotiatesWrap(nil).(VariantAlsoNegotiates) +var ErrHTTPVariantAlsoNegotiates Error = ServerErrorVariantAlsoNegotiates +var ErrVariantAlsoNegotiates error = ServerErrorVariantAlsoNegotiates type VariantAlsoNegotiates interface { ServerError