mirror of
https://codeberg.org/pronounscc/pronouns.cc.git
synced 2024-11-20 10:09:52 +01:00
fix(backend): invert api token check in /auth/warnings/{id}/ack
This commit is contained in:
parent
f608b1046b
commit
c046ae57f2
1 changed files with 1 additions and 1 deletions
|
@ -44,7 +44,7 @@ func (s *Server) ackWarning(w http.ResponseWriter, r *http.Request) (err error)
|
|||
ctx := r.Context()
|
||||
claims, _ := server.ClaimsFromContext(ctx)
|
||||
|
||||
if !claims.APIToken {
|
||||
if claims.APIToken {
|
||||
return server.APIError{Code: server.ErrMissingPermissions, Details: "This endpoint cannot be used by API tokens"}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue