Skip to content

Commit b89bb17

Browse files
committed
refactor: simplify condition
1 parent fb4b1c0 commit b89bb17

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

lib/OnyxUtils.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1173,8 +1173,7 @@ function subscribeToKey<TKey extends OnyxKey>(connectOptions: ConnectOptions<TKe
11731173
cache.addNullishStorageKey(mapping.key);
11741174
}
11751175

1176-
const shouldSendCollectionKey = isCollectionKey(mapping.key) && mapping.waitForCollectionCallback;
1177-
const matchedKey = shouldSendCollectionKey ? mapping.key : undefined;
1176+
const matchedKey = isCollectionKey(mapping.key) && mapping.waitForCollectionCallback ? mapping.key : undefined;
11781177

11791178
// Here we cannot use batching because the nullish value is expected to be set immediately for default props
11801179
// or they will be undefined.

0 commit comments

Comments
 (0)