diff --git a/package.json b/package.json index 29240aaaec3c..4729544d26ec 100644 --- a/package.json +++ b/package.json @@ -43,7 +43,7 @@ "test:debug": "TZ=utc NODE_OPTIONS='--inspect-brk --experimental-vm-modules' jest --runInBand", "perf-test": "NODE_OPTIONS=--experimental-vm-modules npx reassure", "typecheck": "NODE_OPTIONS=--max_old_space_size=8192 tsc", - "lint": "NODE_OPTIONS=--max_old_space_size=8192 eslint . --max-warnings=399 --cache --cache-location=node_modules/.cache/eslint --cache-strategy content --concurrency=auto", + "lint": "NODE_OPTIONS=--max_old_space_size=8192 eslint . --max-warnings=418 --cache --cache-location=node_modules/.cache/eslint --cache-strategy content --concurrency=auto", "lint-changed": "NODE_OPTIONS=--max_old_space_size=8192 ./scripts/lintChanged.sh", "check-lazy-loading": "ts-node scripts/checkLazyLoading.ts", "lint-watch": "npx eslint-watch --watch --changed", diff --git a/src/libs/ReportUtils.ts b/src/libs/ReportUtils.ts index 2f4ccdeb322b..87d8ecbeacfe 100644 --- a/src/libs/ReportUtils.ts +++ b/src/libs/ReportUtils.ts @@ -991,7 +991,7 @@ Onyx.connectWithoutView({ const parsedReportActionMessageCache: Record = {}; let conciergeReportIDOnyxConnect: OnyxEntry; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.CONCIERGE_REPORT_ID, callback: (value) => { conciergeReportIDOnyxConnect = value; @@ -999,7 +999,7 @@ Onyx.connectWithoutView({ }); const defaultAvatarBuildingIconTestID = 'SvgDefaultAvatarBuilding Icon'; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.SESSION, callback: (value) => { // When signed out, val is undefined @@ -1017,7 +1017,7 @@ Onyx.connectWithoutView({ let allPersonalDetails: OnyxEntry; let allPersonalDetailLogins: string[]; let currentUserPersonalDetails: OnyxEntry; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.PERSONAL_DETAILS_LIST, callback: (value) => { if (currentUserAccountID) { @@ -1029,7 +1029,7 @@ Onyx.connectWithoutView({ }); let allReportsDraft: OnyxCollection; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.COLLECTION.REPORT_DRAFT, waitForCollectionCallback: true, callback: (value) => (allReportsDraft = value), @@ -1037,7 +1037,7 @@ Onyx.connectWithoutView({ let allPolicies: OnyxCollection; let hasPolicies: boolean; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.COLLECTION.POLICY, waitForCollectionCallback: true, callback: (value) => { @@ -1047,7 +1047,7 @@ Onyx.connectWithoutView({ }); let allPolicyDrafts: OnyxCollection; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.COLLECTION.POLICY_DRAFTS, waitForCollectionCallback: true, callback: (value) => (allPolicyDrafts = value), @@ -1055,7 +1055,7 @@ Onyx.connectWithoutView({ let allReports: OnyxCollection; let reportsByPolicyID: ReportByPolicyMap; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.COLLECTION.REPORT, waitForCollectionCallback: true, callback: (value) => { @@ -1091,14 +1091,14 @@ Onyx.connectWithoutView({ }); let betaConfiguration: OnyxEntry = {}; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.BETA_CONFIGURATION, callback: (value) => (betaConfiguration = value ?? {}), }); let allTransactions: OnyxCollection = {}; let reportsTransactions: Record = {}; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.COLLECTION.TRANSACTION, waitForCollectionCallback: true, callback: (value) => { @@ -1124,7 +1124,7 @@ Onyx.connectWithoutView({ }); let allReportActions: OnyxCollection; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.COLLECTION.REPORT_ACTIONS, waitForCollectionCallback: true, callback: (actions) => { @@ -1137,7 +1137,7 @@ Onyx.connectWithoutView({ let allReportMetadata: OnyxCollection; const allReportMetadataKeyValue: Record = {}; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.COLLECTION.REPORT_METADATA, waitForCollectionCallback: true, callback: (value) => { @@ -1158,7 +1158,7 @@ Onyx.connectWithoutView({ }); let allReportNameValuePair: OnyxCollection; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.COLLECTION.REPORT_NAME_VALUE_PAIRS, waitForCollectionCallback: true, callback: (value) => { @@ -1170,7 +1170,7 @@ Onyx.connectWithoutView({ }); let allReportsViolations: OnyxCollection; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.COLLECTION.REPORT_VIOLATIONS, waitForCollectionCallback: true, callback: (value) => { @@ -1182,13 +1182,13 @@ Onyx.connectWithoutView({ }); let onboarding: OnyxEntry; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.NVP_ONBOARDING, callback: (value) => (onboarding = value), }); let delegateEmail = ''; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.ACCOUNT, callback: (value) => { delegateEmail = value?.delegatedAccess?.delegate ?? ''; @@ -1196,7 +1196,7 @@ Onyx.connectWithoutView({ }); let reportAttributesDerivedValue: ReportAttributesDerivedValue['reports']; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.DERIVED.REPORT_ATTRIBUTES, callback: (value) => { reportAttributesDerivedValue = value?.reports ?? {}; @@ -1204,7 +1204,7 @@ Onyx.connectWithoutView({ }); let cachedSelfDMReportID: OnyxEntry; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.SELF_DM_REPORT_ID, callback: (value) => (cachedSelfDMReportID = value), }); @@ -1212,7 +1212,7 @@ Onyx.connectWithoutView({ let hiddenTranslation = ''; let unavailableTranslation = ''; -Onyx.connectWithoutView({ +Onyx.connect({ key: ONYXKEYS.ARE_TRANSLATIONS_LOADING, initWithStoredValues: false, callback: (value) => {