Skip to content

Commit acd0021

Browse files
authored
Merge pull request Expensify#67710 from DylanDylann/remove-onyx-connect-in-QueuedOnyxUpdates
[No QA]: Remove Onyx.connect() for the key: ONYXKEYS.SESSION in src/libs/actions/QueuedOnyxUpdates.ts
2 parents 0494a24 + d9fb9ed commit acd0021

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
"test:debug": "TZ=utc NODE_OPTIONS='--inspect-brk --experimental-vm-modules' jest --runInBand",
4747
"perf-test": "NODE_OPTIONS=--experimental-vm-modules npx reassure",
4848
"typecheck": "NODE_OPTIONS=--max_old_space_size=8192 tsc",
49-
"lint": "NODE_OPTIONS=--max_old_space_size=8192 eslint . --max-warnings=311 --cache --cache-location=node_modules/.cache/eslint",
49+
"lint": "NODE_OPTIONS=--max_old_space_size=8192 eslint . --max-warnings=310 --cache --cache-location=node_modules/.cache/eslint",
5050
"lint-changed": "NODE_OPTIONS=--max_old_space_size=8192 ./scripts/lintChanged.sh",
5151
"lint-watch": "npx eslint-watch --watch --changed",
5252
"shellcheck": "./scripts/shellCheck.sh",

src/libs/actions/QueuedOnyxUpdates.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@ import ONYXKEYS from '@src/ONYXKEYS';
88
let queuedOnyxUpdates: OnyxUpdate[] = [];
99
let currentAccountID: number | undefined;
1010

11-
Onyx.connect({
11+
// We use `connectWithoutView` because it is not connected to any UI component.
12+
Onyx.connectWithoutView({
1213
key: ONYXKEYS.SESSION,
1314
callback: (session) => {
1415
currentAccountID = session?.accountID;

0 commit comments

Comments
 (0)