1
0
Fork 0
mirror of https://github.com/documize/community.git synced 2025-07-19 21:29:42 +02:00

Fixed an issue with non-admin Jira connector auth

Role check should be OR and not AND.
This commit is contained in:
sauls8t 2019-01-24 16:57:23 +00:00
parent 2e443de84e
commit c0c3ca18e2

View file

@ -60,12 +60,7 @@ func (h *Handler) RunSectionCommand(w http.ResponseWriter, r *http.Request) {
// it's up to the section handler to parse if required. // it's up to the section handler to parse if required.
// Permission checks // Permission checks
if !permission.CanChangeDocument(ctx, *h.Store, documentID) { if !ctx.Editor && !permission.CanChangeDocument(ctx, *h.Store, documentID) {
response.WriteForbiddenError(w)
return
}
if !ctx.Editor {
response.WriteForbiddenError(w) response.WriteForbiddenError(w)
return return
} }