🐛 Set proper exception type on notauthorized requests.

This commit is contained in:
Andrey Antukh 2021-01-19 11:29:56 +01:00 committed by Alonso Torres
parent 9805f8b9f2
commit af310854fc
3 changed files with 6 additions and 6 deletions

View file

@ -71,7 +71,7 @@
(when-not (or (some :can-edit rows)
(some :is-admin rows)
(some :is-owner rows))
(ex/raise :type :validation
(ex/raise :type :authorization
:code :not-authorized))))
@ -82,7 +82,7 @@
file-id profile-id
file-id profile-id])]
(when-not (seq rows)
(ex/raise :type :validation
(ex/raise :type :authorization
:code :not-authorized))))