0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-01-10 00:40:30 -05:00

Do not fetch history on each history navigation action.

This commit is contained in:
Andrey Antukh 2016-03-27 18:31:45 +03:00
parent 8c64c7c3eb
commit 0746385555

View file

@ -41,7 +41,8 @@
(let [page @wb/page-l]
(rs/emit! (dpg/fetch-page-history (:id page)))
(add-watch wb/page-l ::key (fn [_ _ ov nv]
(when (> (:version nv) (:version ov))
(when (and (> (:version nv) (:version ov))
(not (:history nv)))
(rs/emit! (dpg/fetch-page-history (:id nv))))))
own))