0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-02-12 18:18:24 -05:00

🐛 Fix wrong argument number on recursive delete operation (shapes).

This commit is contained in:
Andrey Antukh 2020-11-30 15:57:32 +01:00 committed by Hirunatan
parent 6f64053dd5
commit f4124b28d8

View file

@ -807,7 +807,7 @@
(defmethod process-change :del-obj
[data {:keys [page-id component-id id ignore-touched] :as change}]
(letfn [(delete-object [objects]
(letfn [(delete-object [objects id]
(if-let [target (get objects id)]
(let [parent-id (cph/get-parent id objects)
frame-id (:frame-id target)
@ -829,8 +829,8 @@
(as-> $ (reduce delete-object $ (:shapes target)))))
objects))]
(if page-id
(d/update-in-when data [:pages-index page-id :objects] delete-object)
(d/update-in-when data [:components component-id :objects] delete-object))))
(d/update-in-when data [:pages-index page-id :objects] delete-object id)
(d/update-in-when data [:components component-id :objects] delete-object id))))
(defn rotation-modifiers
[center shape angle]