mirror of
https://github.com/penpot/penpot.git
synced 2025-05-06 10:35:54 +02:00
🐛 Properly send 403 on not authorized request.
This commit is contained in:
parent
dabbbc2e09
commit
fee2eea87c
1 changed files with 1 additions and 1 deletions
|
@ -56,7 +56,7 @@
|
||||||
(spx/terminate (assoc data ::unauthorized true)))))
|
(spx/terminate (assoc data ::unauthorized true)))))
|
||||||
(vc/handle-on-context))))
|
(vc/handle-on-context))))
|
||||||
:leave (fn [data]
|
:leave (fn [data]
|
||||||
(if (and (::unauthorized data) (:response data))
|
(if (::unauthorized data)
|
||||||
(update data :response
|
(update data :response
|
||||||
assoc :status 403 :body {:type :authentication
|
assoc :status 403 :body {:type :authentication
|
||||||
:code :unauthorized})
|
:code :unauthorized})
|
||||||
|
|
Loading…
Add table
Reference in a new issue