Reference picker: fix show existing key as unexistent in Insert mode

This commit is contained in:
yu-i-i
2026-09-22 02:41:44 +02:00
parent b3a57cf3e2
commit cd516bdc12
@@ -109,9 +109,10 @@ export default function ReferencePickerModal({
setResults(r.hits)
const known = new Set(r.hits.map(h => h._source.EntryKey))
setKnownKeys(known)
if (pendingInitialKeysRef.current.length > 0) {
const known = new Set(r.hits.map(h => h._source.EntryKey))
setKnownKeys(known)
setSelectedKeys([...pendingInitialKeysRef.current])
pendingInitialKeysRef.current = []
}