chore: code clean (#516)

This commit is contained in:
boojack
2022-11-21 23:23:05 +08:00
committed by GitHub
parent 0d0f893b93
commit 013ded1e04
4 changed files with 7 additions and 6 deletions

View File

@@ -105,7 +105,7 @@ func aclMiddleware(s *Server, next echo.HandlerFunc) echo.HandlerFunc {
return next(c)
}
if common.HasPrefixes(path, "/api/memo", "/api/tag", "/api/shortcut", "/api/memo/stats") && c.Request().Method == http.MethodGet {
if common.HasPrefixes(path, "/api/memo", "/api/tag", "/api/shortcut") && c.Request().Method == http.MethodGet {
if _, err := strconv.Atoi(c.QueryParam("creatorId")); err == nil {
return next(c)
}