You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 24, 2023. It is now read-only.
Hello,
I was wondering if it's and intended behavior...
(Code may be better to explain)
The default error handler is written
ifcfg.ErrorHandler==nil {
cfg.ErrorHandler=func(c*fiber.Ctx, errerror) error {
iferr.Error() =="Missing or malformed JWT" {
returnc.Status(fiber.StatusBadRequest).SendString("Missing or malformed JWT")
} else {
returnc.Status(fiber.StatusUnauthorized).SendString("Invalid or expired JWT")
}
}
}
This way the error is not processed trough the app error handler
Should it not be that way to be processed by any application level error handler by default?
ifcfg.ErrorHandler==nil {
cfg.ErrorHandler=func(c*fiber.Ctx, errerror) error {
iferr.Error() =="Missing or malformed JWT" {
returnfiber.NewError(fiber.StatusBadRequest, "Missing or malformed JWT")
} else {
returnfiber.NewError(fiber.StatusUnauthorized, "Invalid or expired JWT")
}
}
}
Not sure if i am clear enough 😅
The text was updated successfully, but these errors were encountered:
Hello,
I was wondering if it's and intended behavior...
(Code may be better to explain)
The default error handler is written
This way the error is not processed trough the app error handler
Should it not be that way to be processed by any application level error handler by default?
Not sure if i am clear enough 😅
The text was updated successfully, but these errors were encountered: