Skip to content

Commit 143d1c0

Browse files
committed
Fix: use strict comparison
1 parent 66a1cb9 commit 143d1c0

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

packages/firestore/src/local/local_documents_view.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ export class LocalDocumentsView {
168168
// the change (hence overlay==null), but would now match.
169169
if (
170170
existenceStateChanged.has(doc.key) &&
171-
(overlay == null || overlay.mutation instanceof PatchMutation)
171+
(overlay === null || overlay.mutation instanceof PatchMutation)
172172
) {
173173
recalculateDocuments = recalculateDocuments.insert(doc.key, doc);
174174
} else if (overlay !== null) {
@@ -413,7 +413,7 @@ export class LocalDocumentsView {
413413
key: DocumentKey,
414414
overlay: Overlay | null
415415
): PersistencePromise<MutableDocument> {
416-
return overlay == null || overlay.mutation instanceof PatchMutation
416+
return overlay === null || overlay.mutation instanceof PatchMutation
417417
? this.remoteDocumentCache.getEntry(transaction, key)
418418
: PersistencePromise.resolve(MutableDocument.newInvalidDocument(key));
419419
}

packages/firestore/src/model/mutation.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -372,7 +372,7 @@ export function mutationExtractBaseValue(
372372
);
373373

374374
if (coercedValue != null) {
375-
if (baseObject == null) {
375+
if (baseObject === null) {
376376
baseObject = ObjectValue.empty();
377377
}
378378
baseObject.set(fieldTransform.field, coercedValue);

0 commit comments

Comments
 (0)