mirror of
https://github.com/logseq/logseq.git
synced 2026-06-01 19:01:22 +00:00
fix: batch temp-id remapping applies only to neg integer temp IDs
not string IDs
This commit is contained in:
@@ -558,6 +558,10 @@
|
||||
(or (and (integer? x) (neg? x))
|
||||
(string? x)))
|
||||
|
||||
(defn- remappable-remote-temp-id?
|
||||
[x]
|
||||
(and (integer? x) (neg? x)))
|
||||
|
||||
(defn- remap-remote-batch-temp-ids
|
||||
[batch-index tx-data]
|
||||
(let [ops #{:db/add :db/retract :db/retractEntity}
|
||||
@@ -566,7 +570,7 @@
|
||||
(when (and (vector? item)
|
||||
(>= (count item) 2)
|
||||
(contains? ops (first item))
|
||||
(remote-temp-id? (second item)))
|
||||
(remappable-remote-temp-id? (second item)))
|
||||
(second item))))
|
||||
distinct)
|
||||
temp-id-map (when (seq entity-temp-ids)
|
||||
|
||||
Reference in New Issue
Block a user