mirror of
https://github.com/penpot/penpot.git
synced 2025-02-03 21:09:00 -05:00
✨ Add file version on binfile import logging
This commit is contained in:
parent
1b889cb141
commit
b53f7eaa19
1 changed files with 8 additions and 4 deletions
|
@ -659,20 +659,24 @@
|
||||||
:hint "the penpot file seems corrupt, found unexpected uuid (file-id)"))
|
:hint "the penpot file seems corrupt, found unexpected uuid (file-id)"))
|
||||||
|
|
||||||
;; Update index using with media
|
;; Update index using with media
|
||||||
(l/debug :hint "update index with media" ::l/sync? true)
|
(l/dbg :hint "update index with media" ::l/sync? true)
|
||||||
(vswap! *state* update :index update-index (map :id media'))
|
(vswap! *state* update :index update-index (map :id media'))
|
||||||
|
|
||||||
;; Store file media for later insertion
|
;; Store file media for later insertion
|
||||||
(l/debug :hint "update media references" ::l/sync? true)
|
(l/dbg :hint "update media references" ::l/sync? true)
|
||||||
(vswap! *state* update :media into (map #(update % :id lookup-index)) media')
|
(vswap! *state* update :media into (map #(update % :id lookup-index)) media')
|
||||||
|
|
||||||
(l/debug :hint "processing file" :file-id file-id ::features features ::l/sync? true)
|
|
||||||
|
|
||||||
(binding [ffeat/*current* features
|
(binding [ffeat/*current* features
|
||||||
ffeat/*wrap-with-objects-map-fn* (if (features "storage/objects-map") omap/wrap identity)
|
ffeat/*wrap-with-objects-map-fn* (if (features "storage/objects-map") omap/wrap identity)
|
||||||
ffeat/*wrap-with-pointer-map-fn* (if (features "storage/pointer-map") pmap/wrap identity)
|
ffeat/*wrap-with-pointer-map-fn* (if (features "storage/pointer-map") pmap/wrap identity)
|
||||||
pmap/*tracked* (atom {})]
|
pmap/*tracked* (atom {})]
|
||||||
|
|
||||||
|
(l/dbg :hint "processing file"
|
||||||
|
:id file-id
|
||||||
|
:features features
|
||||||
|
:version (-> file :data :version)
|
||||||
|
::l/sync? true)
|
||||||
|
|
||||||
(let [file-id' (lookup-index file-id)
|
(let [file-id' (lookup-index file-id)
|
||||||
data (-> (:data file)
|
data (-> (:data file)
|
||||||
(assoc :id file-id')
|
(assoc :id file-id')
|
||||||
|
|
Loading…
Add table
Reference in a new issue