Merge pull request #6111 from penpot/superalex-fix-pen-shortcut-multiple-times

🐛 Fix opening pen with shortcut multiple times breaks toolbar
This commit is contained in:
Alejandro 2025-03-20 18:05:35 +01:00 committed by GitHub
commit 9fb7456b38
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 4 additions and 1 deletions

View file

@ -324,7 +324,9 @@
(let [id (dm/get-in state [:workspace-local :edition])
objects (dsh/lookup-page-objects state)
content (dm/get-in objects [id :content])]
(update-in state [:workspace-local :edit-path id] assoc :old-content content)))
(if content
(update-in state [:workspace-local :edit-path id] assoc :old-content content)
state)))
ptk/WatchEvent
(watch [_ state stream]