mirror of
https://github.com/penpot/penpot.git
synced 2025-02-10 09:08:31 -05:00
Fix image initialization event.
This commit is contained in:
parent
934fcba179
commit
5762ee0bf3
1 changed files with 4 additions and 4 deletions
|
@ -26,14 +26,14 @@
|
|||
(let [type (or type :builtin)
|
||||
id (or id (if (= type :builtin) 1 nil))
|
||||
data {:type type :id id :selected #{}}]
|
||||
(println "initialize:" data)
|
||||
(-> state
|
||||
(assoc-in [:dashboard :images] data)
|
||||
(assoc-in [:dashboard :section] :dashboard/images))))
|
||||
|
||||
rs/WatchEvent
|
||||
(-apply-watch [_ state s]
|
||||
(rx/merge
|
||||
(rx/of (fetch-collections))
|
||||
(rx/merge (rx/of (fetch-collections))
|
||||
(when (uuid? id)
|
||||
(rx/of (fetch-images id))))))
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue