0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-01-23 23:18:48 -05:00

📎 Add safety check on reg-objects change impl.

This commit is contained in:
Andrey Antukh 2021-05-26 12:14:02 +02:00
parent 67cd877281
commit 2834850337

View file

@ -142,7 +142,7 @@
(defmethod process-change :reg-objects
[data {:keys [page-id component-id shapes]}]
(letfn [(reg-objects [objects]
(reduce #(update %1 %2 update-group %1) objects
(reduce #(d/update-when %1 %2 update-group %1) objects
(sequence (comp
(mapcat #(cons % (cph/get-parents % objects)))
(map #(get objects %))