chore: update skipper name (#1080)

This commit is contained in:
boojack
2023-02-12 17:29:23 +08:00
committed by GitHub
parent a997e1d10d
commit 870559046f
5 changed files with 11 additions and 10 deletions

View File

@ -18,16 +18,16 @@ func composeResponse(data interface{}) response {
}
}
func DefaultGetRequestSkipper(c echo.Context) bool {
func defaultGetRequestSkipper(c echo.Context) bool {
return c.Request().Method == http.MethodGet
}
func DefaultAPIRequestSkipper(c echo.Context) bool {
func defaultAPIRequestSkipper(c echo.Context) bool {
path := c.Path()
return common.HasPrefixes(path, "/api")
}
func (server *Server) DefaultAuthSkipper(c echo.Context) bool {
func (server *Server) defaultAuthSkipper(c echo.Context) bool {
ctx := c.Request().Context()
path := c.Path()