Skip to content

Commit

Permalink
tweak
Browse files Browse the repository at this point in the history
  • Loading branch information
runspired committed Jul 24, 2023
1 parent 3dca02f commit acaed4f
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions packages/store/src/-private/caches/identifier-cache.ts
Original file line number Diff line number Diff line change
Expand Up @@ -445,10 +445,11 @@ export class IdentifierCache {
// If the incoming type does not match the identifier type, we need to create an identifier for the incoming
// data so we can merge the incoming data with the existing identifier, see #7325 and #7363
if (identifier.type !== keyInfo.type) {
let incomingDataResource = { ...data };
// Need to strip the lid from the incomingData in order force a new identifier creation
delete incomingDataResource.lid;
existingIdentifier = this.getOrCreateRecordIdentifier(incomingDataResource);
if (hasLid(data)) {
// Strip the lid to ensure we force a new identifier creation
delete data.lid;
}
existingIdentifier = this.getOrCreateRecordIdentifier(data);
}
}

Expand Down

0 comments on commit acaed4f

Please sign in to comment.