Browse Source

En cours de développement

master
mls-361 9 months ago
parent
commit
80ae6d43c5
  1. 2
      internal/api/middleware.go

2
internal/api/middleware.go

@ -40,7 +40,7 @@ func mwAuth(next jsonapi.Handler, crypto components.Crypto) jsonapi.Handler {
if strings.HasPrefix(r.URL.RequestURI(), "/api/admin/") && username != "cli" {
r.RenderError(
http.StatusUnauthorized,
fmt.Sprintf("this user does not have the permissions: %s", username),
fmt.Sprintf("this user is not authorized: %s", username),
)
return
}

Loading…
Cancel
Save