mirror of
https://github.com/penpot/penpot.git
synced 2025-06-13 02:01:39 +02:00
🐛 Fix cookie elimination issues.
This commit is contained in:
parent
449ca770c1
commit
4dad6bef40
2 changed files with 4 additions and 2 deletions
|
@ -55,7 +55,7 @@
|
||||||
(-> (session/delete token)
|
(-> (session/delete token)
|
||||||
(p/then' (fn [token]
|
(p/then' (fn [token]
|
||||||
{:status 204
|
{:status 204
|
||||||
:cookies {"auth-token" {:value nil}}
|
:cookies {"auth-token" nil}
|
||||||
:body ""})))))
|
:body ""})))))
|
||||||
|
|
||||||
(defn register-handler
|
(defn register-handler
|
||||||
|
|
|
@ -55,7 +55,9 @@
|
||||||
^HttpServerResponse res (get-in data [:request ::vh/response])]
|
^HttpServerResponse res (get-in data [:request ::vh/response])]
|
||||||
(when (map? cookies)
|
(when (map? cookies)
|
||||||
(vu/doseq [[key val] cookies]
|
(vu/doseq [[key val] cookies]
|
||||||
(.addCookie res (build-cookie key val))))
|
(if (nil? val)
|
||||||
|
(.removeCookie res key)
|
||||||
|
(.addCookie res (build-cookie key val)))))
|
||||||
data))})
|
data))})
|
||||||
|
|
||||||
;; --- Params
|
;; --- Params
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue