mirror of
https://github.com/zoriya/Kyoo.git
synced 2025-05-24 02:02:36 -04:00
Revert labstack/echo-jwt#13
This commit is contained in:
parent
d88160218b
commit
d4fbba8aeb
@ -32,6 +32,10 @@ func ErrorHandler(err error, c echo.Context) {
|
|||||||
if he, ok := err.(*echo.HTTPError); ok {
|
if he, ok := err.(*echo.HTTPError); ok {
|
||||||
code = he.Code
|
code = he.Code
|
||||||
message = fmt.Sprint(he.Message)
|
message = fmt.Sprint(he.Message)
|
||||||
|
|
||||||
|
if message == "missing or malformed jwt" {
|
||||||
|
code = http.StatusUnauthorized
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
c.Logger().Error(err)
|
c.Logger().Error(err)
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user