0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-03-11 23:31:21 -05:00

🐛 Fix shadows lost on import export

This commit is contained in:
Alejandro Alonso 2024-03-18 15:48:22 +01:00 committed by Andrey Antukh
parent a5b156e0d6
commit 8363b86cfa

View file

@ -853,11 +853,11 @@
(defn migrate-up-44
[data]
(letfn [(fix-shadow [shadow]
(if (string? (:color shadow))
(let [color {:color (:color shadow)
:opacity 1}]
(assoc shadow :color color))
shadow))
(let [color (if (string? (:color shadow))
{:color (:color shadow)
:opacity 1}
(d/without-nils (:color shadow)))]
(assoc shadow :color color)))
(update-object [object]
(d/update-when object :shadow