0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-01-23 15:09:10 -05:00

🐛 Fixes recursion problems when creating component

This commit is contained in:
alonso.torres 2021-02-03 15:25:14 +01:00 committed by Andrey Antukh
parent d85537fa7b
commit d66452423f

View file

@ -230,7 +230,8 @@
(let [file-id (:current-file-id state)
page-id (:current-page-id state)
objects (dwc/lookup-page-objects state page-id)
selected (get-in state [:workspace-local :selected])]
selected (get-in state [:workspace-local :selected])
selected (cp/clean-loops objects selected)]
(let [[group rchanges uchanges]
(dwlh/generate-add-component selected objects page-id file-id)]
(when-not (empty? rchanges)