mirror of
https://github.com/penpot/penpot.git
synced 2025-06-01 01:41:40 +02:00
Fix wrong state cleaning in logout.
This commit is contained in:
parent
ffc6c79ed7
commit
d1fee179d5
2 changed files with 18 additions and 14 deletions
|
@ -74,7 +74,7 @@
|
||||||
(defrecord Logout []
|
(defrecord Logout []
|
||||||
rs/UpdateEvent
|
rs/UpdateEvent
|
||||||
(-apply-update [_ state]
|
(-apply-update [_ state]
|
||||||
(assoc state :auth nil))
|
(st/get-initial-state))
|
||||||
|
|
||||||
rs/WatchEvent
|
rs/WatchEvent
|
||||||
(-apply-watch [_ state s]
|
(-apply-watch [_ state s]
|
||||||
|
|
|
@ -13,8 +13,9 @@
|
||||||
|
|
||||||
(defonce state (atom {}))
|
(defonce state (atom {}))
|
||||||
|
|
||||||
(defonce stream
|
(defn get-initial-state
|
||||||
(rs/init {:dashboard {:project-order :name
|
[]
|
||||||
|
{:dashboard {:project-order :name
|
||||||
:project-filter ""}
|
:project-filter ""}
|
||||||
:route nil
|
:route nil
|
||||||
:auth (:uxbox/auth local-storage)
|
:auth (:uxbox/auth local-storage)
|
||||||
|
@ -26,7 +27,10 @@
|
||||||
:colors-by-id {}
|
:colors-by-id {}
|
||||||
:icons-by-id {}
|
:icons-by-id {}
|
||||||
:projects-by-id {}
|
:projects-by-id {}
|
||||||
:pages-by-id {}}))
|
:pages-by-id {}})
|
||||||
|
|
||||||
|
(defonce stream
|
||||||
|
(rs/init (get-initial-state)))
|
||||||
|
|
||||||
(defn init
|
(defn init
|
||||||
"Initialize the state materialization."
|
"Initialize the state materialization."
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue