A local-first personal finance app
[AI] lint: await-thenable, no-floating-promises (#6987)
Matiss Janis Aboltins04722119253f
diff --git a/.github/actions/ai-generated-release-notes/check-release-notes-exists.js b/.github/actions/ai-generated-release-notes/check-release-notes-exists.jsindex 977ec25f97..5c21997748 100755--- a/.github/actions/ai-generated-release-notes/check-release-notes-exists.js+++ b/.github/actions/ai-generated-release-notes/check-release-notes-exists.js@@ -74,4 +74,4 @@ async function checkReleaseNotesExists() {}}-checkReleaseNotesExists();+void checkReleaseNotesExists();diff --git a/.github/actions/ai-generated-release-notes/comment-on-pr.js b/.github/actions/ai-generated-release-notes/comment-on-pr.jsindex b0ff5897a5..36a5e4f28f 100755--- a/.github/actions/ai-generated-release-notes/comment-on-pr.js+++ b/.github/actions/ai-generated-release-notes/comment-on-pr.js@@ -74,4 +74,4 @@ async function commentOnPR() {}}-commentOnPR();+void commentOnPR();diff --git a/.github/actions/ai-generated-release-notes/create-release-notes-file.js b/.github/actions/ai-generated-release-notes/create-release-notes-file.jsindex aba3bc840b..1709a3d912 100755--- a/.github/actions/ai-generated-release-notes/create-release-notes-file.js+++ b/.github/actions/ai-generated-release-notes/create-release-notes-file.js@@ -94,4 +94,4 @@ ${summaryData.summary}}}-createReleaseNotesFile();+void createReleaseNotesFile();diff --git a/.github/scripts/count-points.mjs b/.github/scripts/count-points.mjsindex c051bc7ce8..85062be697 100644--- a/.github/scripts/count-points.mjs+++ b/.github/scripts/count-points.mjs@@ -96,7 +96,7 @@ async function getLastCommitBeforeDate(octokit, owner, repo, beforeDate) {* @param {string} repo - Repository name.* @param {number} prNumber - PR number.* @param {Date} monthEnd - The end date of the month to use as base revision.- * @returns {Object} Object with category and points, or null if error.+ * @returns {Promise<Object>} Object with category and points, or null if error.*/async function getPRCategoryAndPoints(octokit,diff --git a/.oxlintrc.json b/.oxlintrc.jsonindex e41c28c941..9bc9841aa4 100644--- a/.oxlintrc.json+++ b/.oxlintrc.json@@ -101,6 +101,8 @@"typescript/no-var-requires": "error",// we want to allow unions such as "{ name: DbAccount['name'] | DbPayee['name'] }""typescript/no-duplicate-type-constituents": "off",+ "typescript/await-thenable": "error",+ "typescript/no-floating-promises": "warn", // TODO: covert to error// Import rules"import/consistent-type-specifier-style": "error",diff --git a/bin/release-note-generator.ts b/bin/release-note-generator.tsindex b23e0fd023..931e71c124 100644--- a/bin/release-note-generator.ts+++ b/bin/release-note-generator.ts@@ -178,4 +178,4 @@ async function execAsync(cmd: string, errorLog?: string): Promise<string> {});}-run();+void run();diff --git a/packages/desktop-client/e2e/accounts.mobile.test.ts b/packages/desktop-client/e2e/accounts.mobile.test.tsindex 93ddc086be..2cb15af140 100644--- a/packages/desktop-client/e2e/accounts.mobile.test.ts+++ b/packages/desktop-client/e2e/accounts.mobile.test.ts@@ -46,7 +46,7 @@ test.describe('Mobile Accounts', () => {await expect(accountPage.heading).toHaveText('Bank of America');await expect(accountPage.transactionList).toBeVisible();- await expect(await accountPage.getBalance()).toBeGreaterThan(0);+ expect(await accountPage.getBalance()).toBeGreaterThan(0);await expect(accountPage.noTransactionsMessage).not.toBeVisible();await expect(page).toMatchThemeScreenshots();diff --git a/packages/desktop-client/e2e/accounts.test.ts b/packages/desktop-client/e2e/accounts.test.tsindex 08ca9302b7..85903c1c03 100644--- a/packages/desktop-client/e2e/accounts.test.ts+++ b/packages/desktop-client/e2e/accounts.test.ts@@ -158,9 +158,7 @@ test.describe('Accounts', () => {await expect(page).toMatchThemeScreenshots();await expect(importButton).toBeDisabled();- await expect(await importButton.innerText()).toMatch(- /Import 0 transactions/,- );+ expect(await importButton.innerText()).toMatch(/Import 0 transactions/);await accountPage.page.getByRole('button', { name: 'Close' }).click();diff --git a/packages/desktop-client/e2e/page-models/mobile-account-page.ts b/packages/desktop-client/e2e/page-models/mobile-account-page.tsindex aa1687c727..702ed67876 100644--- a/packages/desktop-client/e2e/page-models/mobile-account-page.ts+++ b/packages/desktop-client/e2e/page-models/mobile-account-page.ts@@ -56,7 +56,7 @@ export class MobileAccountPage {* Go to transaction creation page*/async clickCreateTransaction() {- this.createTransactionButton.click();+ await this.createTransactionButton.click();return new MobileTransactionEntryPage(this.page);}}diff --git a/packages/desktop-client/e2e/page-models/mobile-budget-page.ts b/packages/desktop-client/e2e/page-models/mobile-budget-page.tsindex 5aa6a91ee2..189a15b7bb 100644--- a/packages/desktop-client/e2e/page-models/mobile-budget-page.ts+++ b/packages/desktop-client/e2e/page-models/mobile-budget-page.ts@@ -148,7 +148,7 @@ export class MobileBudgetPage {return groupNameText;}- #getButtonForCategoryGroup(categoryGroupName: string | RegExp) {+ async #getButtonForCategoryGroup(categoryGroupName: string | RegExp) {return this.categoryGroupRows.getByRole('button', {name: categoryGroupName,exact: true,@@ -169,7 +169,7 @@ export class MobileBudgetPage {return categoryNameText;}- #getButtonForCategory(categoryName: string | RegExp) {+ async #getButtonForCategory(categoryName: string | RegExp) {return this.categoryRows.getByRole('button', {name: categoryName,exact: true,diff --git a/packages/desktop-client/e2e/settings.mobile.test.ts b/packages/desktop-client/e2e/settings.mobile.test.tsindex 979c310091..616bb46e3d 100644--- a/packages/desktop-client/e2e/settings.mobile.test.ts+++ b/packages/desktop-client/e2e/settings.mobile.test.ts@@ -36,9 +36,7 @@ test.describe('Mobile Settings', () => {const download = await downloadPromise;- expect(await download.suggestedFilename()).toMatch(- /^\d{4}-\d{2}-\d{2}-.*.zip$/,- );+ expect(download.suggestedFilename()).toMatch(/^\d{4}-\d{2}-\d{2}-.*.zip$/);await expect(page).toMatchThemeScreenshots();});});diff --git a/packages/desktop-client/e2e/settings.test.ts b/packages/desktop-client/e2e/settings.test.tsindex 59c8218287..411a0e1453 100644--- a/packages/desktop-client/e2e/settings.test.ts+++ b/packages/desktop-client/e2e/settings.test.ts@@ -37,8 +37,6 @@ test.describe('Settings', () => {const download = await downloadPromise;- expect(await download.suggestedFilename()).toMatch(- /^\d{4}-\d{2}-\d{2}-.*.zip$/,- );+ expect(download.suggestedFilename()).toMatch(/^\d{4}-\d{2}-\d{2}-.*.zip$/);});});diff --git a/packages/desktop-client/e2e/transactions.test.ts-snapshots/Transactions-creates-a-transfer-test-transaction-4-chromium-linux.png b/packages/desktop-client/e2e/transactions.test.ts-snapshots/Transactions-creates-a-transfer-test-transaction-4-chromium-linux.pngindex dc77a1fa28..5e00c7c462 100644Binary files a/packages/desktop-client/e2e/transactions.test.ts-snapshots/Transactions-creates-a-transfer-test-transaction-4-chromium-linux.png and b/packages/desktop-client/e2e/transactions.test.ts-snapshots/Transactions-creates-a-transfer-test-transaction-4-chromium-linux.png differdiff --git a/packages/desktop-client/e2e/transactions.test.ts-snapshots/Transactions-creates-a-transfer-test-transaction-5-chromium-linux.png b/packages/desktop-client/e2e/transactions.test.ts-snapshots/Transactions-creates-a-transfer-test-transaction-5-chromium-linux.pngindex 84a922f5c3..7ee7523708 100644Binary files a/packages/desktop-client/e2e/transactions.test.ts-snapshots/Transactions-creates-a-transfer-test-transaction-5-chromium-linux.png and b/packages/desktop-client/e2e/transactions.test.ts-snapshots/Transactions-creates-a-transfer-test-transaction-5-chromium-linux.png differdiff --git a/packages/desktop-client/e2e/transactions.test.ts-snapshots/Transactions-creates-a-transfer-test-transaction-6-chromium-linux.png b/packages/desktop-client/e2e/transactions.test.ts-snapshots/Transactions-creates-a-transfer-test-transaction-6-chromium-linux.pngindex d4cc503b14..be479b13d0 100644Binary files a/packages/desktop-client/e2e/transactions.test.ts-snapshots/Transactions-creates-a-transfer-test-transaction-6-chromium-linux.png and b/packages/desktop-client/e2e/transactions.test.ts-snapshots/Transactions-creates-a-transfer-test-transaction-6-chromium-linux.png differdiff --git a/packages/desktop-client/src/accounts/mutations.ts b/packages/desktop-client/src/accounts/mutations.tsindex cc74939a77..d15aa24376 100644--- a/packages/desktop-client/src/accounts/mutations.ts+++ b/packages/desktop-client/src/accounts/mutations.ts@@ -32,7 +32,7 @@ import type { AppDispatch } from '@desktop-client/redux/store';import { setNewTransactions } from '@desktop-client/transactions/transactionsSlice';const invalidateQueries = (queryClient: QueryClient, queryKey?: QueryKey) => {- queryClient.invalidateQueries({+ void queryClient.invalidateQueries({queryKey: queryKey ?? accountQueries.lists(),});};diff --git a/packages/desktop-client/src/app/appSlice.ts b/packages/desktop-client/src/app/appSlice.tsindex 18732a4dfb..fd0273ee00 100644--- a/packages/desktop-client/src/app/appSlice.ts+++ b/packages/desktop-client/src/app/appSlice.ts@@ -65,7 +65,7 @@ export const resetSync = createAppAsyncThunk(options: {onSuccess: () => {// TODO: There won't be a loading indicator for this- dispatch(resetSync());+ void dispatch(resetSync());},},},diff --git a/packages/desktop-client/src/browser-preload.browser.js b/packages/desktop-client/src/browser-preload.browser.jsindex 384927717a..a659f63727 100644--- a/packages/desktop-client/src/browser-preload.browser.js+++ b/packages/desktop-client/src/browser-preload.browser.js@@ -161,7 +161,7 @@ global.Actual = {reader.onload = async function (ev) {const filepath = `/uploads/${filename}`;- window.__actionsForMenu+ void window.__actionsForMenu.uploadFile(filename, ev.target.result).then(() => resolve([filepath]));};diff --git a/packages/desktop-client/src/budget/mutations.ts b/packages/desktop-client/src/budget/mutations.tsindex 5d499df51d..3c7b87d3f0 100644--- a/packages/desktop-client/src/budget/mutations.ts+++ b/packages/desktop-client/src/budget/mutations.ts@@ -20,7 +20,7 @@ import { useDispatch } from '@desktop-client/redux';import type { AppDispatch } from '@desktop-client/redux/store';function invalidateQueries(queryClient: QueryClient, queryKey?: QueryKey) {- queryClient.invalidateQueries({+ void queryClient.invalidateQueries({queryKey: queryKey ?? categoryQueries.lists(),});}diff --git a/packages/desktop-client/src/budgetfiles/budgetfilesSlice.ts b/packages/desktop-client/src/budgetfiles/budgetfilesSlice.tsindex 7571c6151f..b42b5d9a08 100644--- a/packages/desktop-client/src/budgetfiles/budgetfilesSlice.ts+++ b/packages/desktop-client/src/budgetfiles/budgetfilesSlice.ts@@ -22,7 +22,7 @@ export const loadBudgets = createAppAsyncThunk(async (_, { dispatch }) => {const budgets = await send('get-budgets');- await dispatch(setBudgets({ budgets }));+ dispatch(setBudgets({ budgets }));},);@@ -31,7 +31,7 @@ export const loadRemoteFiles = createAppAsyncThunk(async (_, { dispatch }) => {const files = await send('get-remote-files');- await dispatch(setRemoteFiles({ remoteFiles: files }));+ dispatch(setRemoteFiles({ remoteFiles: files }));},);@@ -41,7 +41,7 @@ export const loadAllFiles = createAppAsyncThunk(const budgets = await send('get-budgets');const files = await send('get-remote-files');- await dispatch(setAllFiles({ budgets, remoteFiles: files }));+ dispatch(setAllFiles({ budgets, remoteFiles: files }));return getState().budgetfiles.allFiles;},@@ -56,7 +56,7 @@ type LoadBudgetPayload = {export const loadBudget = createAppAsyncThunk(`${sliceName}/loadBudget`,async ({ id, options = {} }: LoadBudgetPayload, { dispatch }) => {- await dispatch(setAppState({ loadingText: t('Loading...') }));+ dispatch(setAppState({ loadingText: t('Loading...') }));// Loading a budget may failconst { error } = await send('load-budget', { id, ...options });@@ -64,9 +64,7 @@ export const loadBudget = createAppAsyncThunk(if (error) {const message = getSyncError(error, id);if (error === 'out-of-sync-migrations') {- await dispatch(- pushModal({ modal: { name: 'out-of-sync-migrations' } }),- );+ dispatch(pushModal({ modal: { name: 'out-of-sync-migrations' } }));} else if (error === 'out-of-sync-data') {// confirm is not available on iOSif (typeof window.confirm !== 'undefined') {@@ -79,7 +77,7 @@ export const loadBudget = createAppAsyncThunk();if (showBackups) {- await dispatch(+ dispatch(pushModal({ modal: { name: 'load-backup', options: {} } }),);}@@ -90,11 +88,11 @@ export const loadBudget = createAppAsyncThunk(alert(message);}} else {- await dispatch(closeModal());+ dispatch(closeModal());await dispatch(loadPrefs());}- await dispatch(setAppState({ loadingText: null }));+ dispatch(setAppState({ loadingText: null }));},);@@ -103,11 +101,11 @@ export const closeBudget = createAppAsyncThunk(async (_, { dispatch, getState, extra: { queryClient } }) => {const prefs = getState().prefs.local;if (prefs && prefs.id) {- await dispatch(resetApp());+ dispatch(resetApp());queryClient.clear();- await dispatch(setAppState({ loadingText: t('Closing...') }));+ dispatch(setAppState({ loadingText: t('Closing...') }));await send('close-budget');- await dispatch(setAppState({ loadingText: null }));+ dispatch(setAppState({ loadingText: null }));if (localStorage.getItem('SharedArrayBufferOverride')) {window.location.reload();}@@ -120,7 +118,7 @@ export const closeBudgetUI = createAppAsyncThunk(async (_, { dispatch, getState, extra: { queryClient } }) => {const prefs = getState().prefs.local;if (prefs && prefs.id) {- await dispatch(resetApp());+ dispatch(resetApp());queryClient.clear();}},@@ -150,7 +148,7 @@ export const createBudget = createAppAsyncThunk({ testMode = false, demoMode = false }: CreateBudgetPayload,{ dispatch },) => {- await dispatch(+ dispatch(setAppState({loadingText:testMode || demoMode ? t('Making demo...') : t('Creating budget...'),@@ -163,14 +161,14 @@ export const createBudget = createAppAsyncThunk(await send('create-budget', { testMode });}- await dispatch(closeModal());+ dispatch(closeModal());await dispatch(loadAllFiles());await dispatch(loadPrefs());// Set the loadingText to null after we've loaded the budget prefs// so that the existing manager page doesn't flash- await dispatch(setAppState({ loadingText: null }));+ dispatch(setAppState({ loadingText: null }));},);@@ -206,7 +204,7 @@ export const duplicateBudget = createAppAsyncThunk(}try {- await dispatch(+ dispatch(setAppState({loadingText: t('Duplicating: {{oldName}} to: {{newName}}', {oldName,@@ -222,7 +220,7 @@ export const duplicateBudget = createAppAsyncThunk(open: loadBudget,});- await dispatch(closeModal());+ dispatch(closeModal());if (managePage) {await dispatch(loadAllFiles());@@ -233,7 +231,7 @@ export const duplicateBudget = createAppAsyncThunk(? error: new Error('Error duplicating budget: ' + String(error));} finally {- await dispatch(setAppState({ loadingText: null }));+ dispatch(setAppState({ loadingText: null }));}},);@@ -251,7 +249,7 @@ export const importBudget = createAppAsyncThunk(throw new Error(error);}- await dispatch(closeModal());+ dispatch(closeModal());await dispatch(loadPrefs());},);@@ -308,7 +306,7 @@ export const downloadBudget = createAppAsyncThunk({ cloudFileId, replace = false }: DownloadBudgetPayload,{ dispatch },): Promise<string | null> => {- await dispatch(+ dispatch(setAppState({loadingText: t('Downloading...'),}),@@ -329,14 +327,14 @@ export const downloadBudget = createAppAsyncThunk(),cloudFileId,onSuccess: () => {- dispatch(downloadBudget({ cloudFileId, replace }));+ void dispatch(downloadBudget({ cloudFileId, replace }));},};- await dispatch(+ dispatch(pushModal({ modal: { name: 'fix-encryption-key', options: opts } }),);- await dispatch(setAppState({ loadingText: null }));+ dispatch(setAppState({ loadingText: null }));} else if (error.reason === 'file-exists') {alert(t(@@ -362,7 +360,7 @@ export const downloadBudget = createAppAsyncThunk(downloadBudget({ cloudFileId, replace: true }),).unwrap();} else {- await dispatch(setAppState({ loadingText: null }));+ dispatch(setAppState({ loadingText: null }));alert(getDownloadError(error));}return null;@@ -375,7 +373,7 @@ export const downloadBudget = createAppAsyncThunk(dispatch(loadAllFiles()),dispatch(loadBudget({ id })),]);- await dispatch(setAppState({ loadingText: null }));+ dispatch(setAppState({ loadingText: null }));return id;}},diff --git a/packages/desktop-client/src/components/App.tsx b/packages/desktop-client/src/components/App.tsxindex d42f907c1d..ea5904cb1f 100644--- a/packages/desktop-client/src/components/App.tsx+++ b/packages/desktop-client/src/components/App.tsx@@ -115,7 +115,7 @@ function AppInner() {if (files) {const remoteFile = files.find(f => f.fileId === cloudFileId);if (remoteFile && remoteFile.deleted) {- dispatch(closeBudget());+ void dispatch(closeBudget());}}@@ -146,7 +146,7 @@ function AppInner() {button: {title: t('Go to login'),action: () => {- dispatch(signOut());+ void dispatch(signOut());},},},diff --git a/packages/desktop-client/src/components/CommandBar.tsx b/packages/desktop-client/src/components/CommandBar.tsxindex 27965aa241..477c97142c 100644--- a/packages/desktop-client/src/components/CommandBar.tsx+++ b/packages/desktop-client/src/components/CommandBar.tsx@@ -168,7 +168,7 @@ export function CommandBar() {const handleNavigate = useCallback((path: string) => {setOpen(false);- navigate(path);+ void navigate(path);},[navigate],);diff --git a/packages/desktop-client/src/components/FinancesApp.tsx b/packages/desktop-client/src/components/FinancesApp.tsxindex ca05a40041..7cba4f177e 100644--- a/packages/desktop-client/src/components/FinancesApp.tsx+++ b/packages/desktop-client/src/components/FinancesApp.tsx@@ -51,7 +51,7 @@ function NarrowNotSupported({const navigate = useNavigate();useEffect(() => {if (isNarrowWidth) {- navigate(redirectTo);+ void navigate(redirectTo);}}, [isNarrowWidth, navigate, redirectTo]);return isNarrowWidth ? null : children;@@ -68,7 +68,7 @@ function WideNotSupported({const navigate = useNavigate();useEffect(() => {if (!isNarrowWidth) {- navigate(redirectTo);+ void navigate(redirectTo);}}, [isNarrowWidth, navigate, redirectTo]);return isNarrowWidth ? children : null;@@ -136,13 +136,13 @@ export function FinancesApp() {);}- run();+ void run();});useEffect(() => init(), []);useEffect(() => {- dispatch(getLatestAppVersion());+ void dispatch(getLatestAppVersion());}, [dispatch]);useEffect(() => {diff --git a/packages/desktop-client/src/components/GlobalKeys.ts b/packages/desktop-client/src/components/GlobalKeys.tsindex c2c86c67ee..0877ea8a3b 100644--- a/packages/desktop-client/src/components/GlobalKeys.ts+++ b/packages/desktop-client/src/components/GlobalKeys.ts@@ -15,17 +15,17 @@ export function GlobalKeys() {if (e.metaKey) {switch (e.key) {case '1':- navigate('/budget');+ void navigate('/budget');break;case '2':- navigate('/reports');+ void navigate('/reports');break;case '3':- navigate('/accounts');+ void navigate('/accounts');break;case ',':if (Platform.OS === 'mac') {- navigate('/settings');+ void navigate('/settings');}break;default:diff --git a/packages/desktop-client/src/components/LoggedInUser.tsx b/packages/desktop-client/src/components/LoggedInUser.tsxindex c386b4f6a8..5dc4a411c3 100644--- a/packages/desktop-client/src/components/LoggedInUser.tsx+++ b/packages/desktop-client/src/components/LoggedInUser.tsx@@ -68,7 +68,7 @@ export function LoggedInUser({}, [dispatch]);useEffect(() => {- initializeUserData();+ void initializeUserData();}, [initializeUserData]);useEffect(() => {@@ -85,7 +85,7 @@ export function LoggedInUser({(type === 'error' && !userData.offline));if (shouldReinitialize) {- initializeUserData();+ void initializeUserData();} else {setLoading(false);}@@ -98,7 +98,7 @@ export function LoggedInUser({async function onChangePassword() {await onCloseBudget();- navigate('/change-password');+ void navigate('/change-password');}const handleMenuSelect = async (type: string) => {@@ -106,27 +106,27 @@ export function LoggedInUser({switch (type) {case 'change-password':- onChangePassword();+ void onChangePassword();break;case 'sign-in':await onCloseBudget();- navigate('/login');+ void navigate('/login');break;case 'user-access':- navigate('/user-access');+ void navigate('/user-access');break;case 'user-directory':- navigate('/user-directory');+ void navigate('/user-directory');break;case 'index':- navigate('/');+ void navigate('/');break;case 'sign-out':- dispatch(signOut());+ void dispatch(signOut());break;case 'config-server':await onCloseBudget();- navigate('/config-server');+ void navigate('/config-server');break;default:break;diff --git a/packages/desktop-client/src/components/ManageRules.tsx b/packages/desktop-client/src/components/ManageRules.tsxindex 61395cbcec..482379419e 100644--- a/packages/desktop-client/src/components/ManageRules.tsx+++ b/packages/desktop-client/src/components/ManageRules.tsx@@ -197,7 +197,7 @@ export function ManageRules({undo.setUndoState('openModal', { name: 'manage-rules', options: {} });}- loadData();+ void loadData();return () => {undo.setUndoState('openModal', null);diff --git a/packages/desktop-client/src/components/Modals.tsx b/packages/desktop-client/src/components/Modals.tsxindex 856279616f..69448ba472 100644--- a/packages/desktop-client/src/components/Modals.tsx+++ b/packages/desktop-client/src/components/Modals.tsx@@ -190,7 +190,7 @@ export function Modals() {{...modal.options}onClose={() => {modal.options.onClose?.();- send('gocardless-poll-web-token-stop');+ void send('gocardless-poll-web-token-stop');}}/>);diff --git a/packages/desktop-client/src/components/Notifications.tsx b/packages/desktop-client/src/components/Notifications.tsxindex 455b34ab33..01c240ec01 100644--- a/packages/desktop-client/src/components/Notifications.tsx+++ b/packages/desktop-client/src/components/Notifications.tsx@@ -58,7 +58,7 @@ function compileMessage(e.preventDefault();if (actions[actionName]) {setLoading(true);- await actions[actionName]();+ actions[actionName]();onRemove?.();}}}@@ -162,13 +162,13 @@ function Notification({// Update scale, opacity, and y-position when index changesuseEffect(() => {- api.start({ scale, opacity: stackOpacity, y: yOffset });+ void api.start({ scale, opacity: stackOpacity, y: yOffset });}, [index, scale, stackOpacity, yOffset, api]);const swipeHandlers = useSwipeable({onSwiping: ({ deltaX }) => {if (!isSwiped) {- api.start({ x: deltaX });+ void api.start({ x: deltaX });}},onSwiped: ({ velocity, deltaX }) => {@@ -178,7 +178,7 @@ function Notification({if (Math.abs(deltaX) > threshold || velocity > 0.5) {// Animate out & remove item after animation- api.start({+ void api.start({x: direction * 1000,opacity: 0,onRest: onRemove,@@ -186,7 +186,7 @@ function Notification({setIsSwiped(true);} else {// Reset position if not swiped far enough- api.start({ x: 0 });+ void api.start({ x: 0 });}},trackMouse: true,diff --git a/packages/desktop-client/src/components/ServerContext.tsx b/packages/desktop-client/src/components/ServerContext.tsxindex ea6f49edf5..bd404aff9b 100644--- a/packages/desktop-client/src/components/ServerContext.tsx+++ b/packages/desktop-client/src/components/ServerContext.tsx@@ -107,7 +107,7 @@ export function ServerProvider({ children }: { children: ReactNode }) {setServerURL(serverURL);setVersion(await getServerVersion());}- run();+ void run();}, []);const refreshLoginMethods = useCallback(async () => {@@ -135,7 +135,7 @@ export function ServerProvider({ children }: { children: ReactNode }) {useEffect(() => {if (serverURL) {- send('subscribe-needs-bootstrap').then(+ void send('subscribe-needs-bootstrap').then((data: Awaited<ReturnType<Handlers['subscribe-needs-bootstrap']>>) => {if ('hasServer' in data && data.hasServer) {setAvailableLoginMethods(data.availableLoginMethods || []);diff --git a/packages/desktop-client/src/components/UpdateNotification.tsx b/packages/desktop-client/src/components/UpdateNotification.tsxindex 43e7c5d249..deb60c8c5b 100644--- a/packages/desktop-client/src/components/UpdateNotification.tsx+++ b/packages/desktop-client/src/components/UpdateNotification.tsx@@ -21,7 +21,7 @@ export function UpdateNotification() {const dispatch = useDispatch();const onRestart = () => {- dispatch(updateApp());+ void dispatch(updateApp());};if (updateInfo && showUpdateNotification) {diff --git a/packages/desktop-client/src/components/accounts/Account.tsx b/packages/desktop-client/src/components/accounts/Account.tsxindex fbf94c0058..9a175663b8 100644--- a/packages/desktop-client/src/components/accounts/Account.tsx+++ b/packages/desktop-client/src/components/accounts/Account.tsx@@ -383,13 +383,13 @@ class AccountInternal extends PureComponent<// Important that any async work happens last so that the// listeners are set up synchronously- await this.fetchTransactions(this.state.filterConditions);+ this.fetchTransactions(this.state.filterConditions);// If there is a pending undo, apply it immediately (this happens// when an undo changes the location to this page)const lastUndoEvent = undo.getUndoState('undoEvent');if (lastUndoEvent) {- onUndo(lastUndoEvent);+ void onUndo(lastUndoEvent);}}@@ -407,7 +407,7 @@ class AccountInternal extends PureComponent<// things are listening to transactions and refetch// automatically (use ActualQL?)setTimeout(() => {- this.refetchTransactions();+ void this.refetchTransactions();}, 100);}@@ -442,13 +442,13 @@ class AccountInternal extends PureComponent<};refetchTransactions = async () => {- this.paged?.run();+ void this.paged?.run();};fetchTransactions = (filterConditions?: ConditionEntity[]) => {const query = this.makeRootTransactionsQuery();this.rootQuery = this.currentQuery = query;- if (filterConditions) this.applyFilters(filterConditions);+ if (filterConditions) void this.applyFilters(filterConditions);else this.updateQuery(query);if (this.props.accountId) {@@ -622,7 +622,7 @@ class AccountInternal extends PureComponent<accountName && accountName.replace(/[()]/g, '').replace(/\s+/g, '-');const filename = `${normalizedName || 'transactions'}.csv`;- window.Actual.saveFile(+ void window.Actual.saveFile(exportedTransactions,filename,t('Export transactions'),@@ -817,14 +817,14 @@ class AccountInternal extends PureComponent<);break;case 'close':- this.props.dispatch(openAccountCloseModal({ accountId }));+ void this.props.dispatch(openAccountCloseModal({ accountId }));break;case 'reopen':this.props.onReopenAccount(accountId);break;case 'export':const accountName = this.getAccountTitle(account, accountId);- this.onExport(accountName);+ void this.onExport(accountName);break;case 'toggle-balance':if (this.state.showBalances) {@@ -851,7 +851,7 @@ class AccountInternal extends PureComponent<this.setState({ sort: null }, () => {const filterConditions = this.state.filterConditions;if (filterConditions.length > 0) {- this.applyFilters([...filterConditions]);+ void this.applyFilters([...filterConditions]);} else {this.fetchTransactions();}@@ -1070,18 +1070,18 @@ class AccountInternal extends PureComponent<};onShowTransactions = async (ids: string[]) => {- this.onApplyFilter({+ void this.onApplyFilter({customName: t('Selected transactions'),queryFilter: { id: { $oneof: ids } },});};onBatchEdit = (name: keyof TransactionEntity, ids: string[]) => {- this.props.onBatchEdit({+ void this.props.onBatchEdit({name,ids,onSuccess: updatedIds => {- this.refetchTransactions();+ void this.refetchTransactions();if (this.table.current) {this.table.current.edit(updatedIds[0], 'select', false);@@ -1091,11 +1091,14 @@ class AccountInternal extends PureComponent<};onBatchDuplicate = (ids: string[]) => {- this.props.onBatchDuplicate({ ids, onSuccess: this.refetchTransactions });+ void this.props.onBatchDuplicate({+ ids,+ onSuccess: this.refetchTransactions,+ });};onBatchDelete = (ids: string[]) => {- this.props.onBatchDelete({ ids, onSuccess: this.refetchTransactions });+ void this.props.onBatchDelete({ ids, onSuccess: this.refetchTransactions });};onMakeAsSplitTransaction = async (ids: string[]) => {@@ -1134,7 +1137,7 @@ class AccountInternal extends PureComponent<updated: childTransactions,});- this.refetchTransactions();+ void this.refetchTransactions();};onMakeAsNonSplitTransactions = async (ids: string[]) => {@@ -1204,7 +1207,7 @@ class AccountInternal extends PureComponent<await send('transactions-batch-update', changes);- this.refetchTransactions();+ void this.refetchTransactions();const transactionsToSelect = changes.updated.map(t => t.id);this.dispatchSelected?.({@@ -1257,7 +1260,7 @@ class AccountInternal extends PureComponent<};onBatchLinkSchedule = (ids: string[]) => {- this.props.onBatchLinkSchedule({+ void this.props.onBatchLinkSchedule({ids,account: this.props.accounts.find(a => a.id === this.props.accountId),onSuccess: this.refetchTransactions,@@ -1265,7 +1268,7 @@ class AccountInternal extends PureComponent<};onBatchUnlinkSchedule = (ids: string[]) => {- this.props.onBatchUnlinkSchedule({+ void this.props.onBatchUnlinkSchedule({ids,onSuccess: this.refetchTransactions,});@@ -1364,7 +1367,7 @@ class AccountInternal extends PureComponent<this.setState({filterId: { ...this.state.filterId, status: 'changed' } as SavedFilter,});- this.applyFilters([...this.state.filterConditions]);+ void this.applyFilters([...this.state.filterConditions]);if (this.state.search !== '') {this.onSearch(this.state.search);}@@ -1376,13 +1379,13 @@ class AccountInternal extends PureComponent<f => f.id === this.state.filterId?.id,);this.setState({ filterConditionsOp: savedFilter.conditionsOp ?? 'and' });- this.applyFilters([...savedFilter.conditions]);+ void this.applyFilters([...savedFilter.conditions]);} else {if (savedFilter.status) {this.setState({filterConditionsOp: savedFilter.conditionsOp ?? 'and',});- this.applyFilters([...(savedFilter.conditions ?? [])]);+ void this.applyFilters([...(savedFilter.conditions ?? [])]);}}this.setState({ filterId: { ...this.state.filterId, ...savedFilter } });@@ -1391,7 +1394,7 @@ class AccountInternal extends PureComponent<onClearFilters = () => {this.setState({ filterConditionsOp: 'and' });this.setState({ filterId: undefined });- this.applyFilters([]);+ void this.applyFilters([]);if (this.state.search !== '') {this.onSearch(this.state.search);}@@ -1401,7 +1404,7 @@ class AccountInternal extends PureComponent<oldCondition: RuleConditionEntity,updatedCondition: RuleConditionEntity,) => {- this.applyFilters(+ void this.applyFilters(this.state.filterConditions.map(c =>c === oldCondition ? updatedCondition : c,),@@ -1418,7 +1421,9 @@ class AccountInternal extends PureComponent<};onDeleteFilter = (condition: RuleConditionEntity) => {- this.applyFilters(this.state.filterConditions.filter(c => c !== condition));+ void this.applyFilters(+ this.state.filterConditions.filter(c => c !== condition),+ );if (this.state.filterConditions.length === 1) {this.setState({ filterId: undefined });this.setState({ filterConditionsOp: 'and' });@@ -1456,7 +1461,7 @@ class AccountInternal extends PureComponent<filterId: { ...savedFilter, status: 'saved' },});this.setState({ filterConditionsOp: savedFilter.conditionsOp });- this.applyFilters([...savedFilter.conditions]);+ void this.applyFilters([...savedFilter.conditions]);} else {// A condition was passed in.const condition = conditionOrSavedFilter;@@ -1472,7 +1477,7 @@ class AccountInternal extends PureComponent<status: this.state.filterId && 'changed',} as SavedFilter,});- this.applyFilters([...filterConditions, condition]);+ void this.applyFilters([...filterConditions, condition]);}if (this.state.search !== '') {@@ -1491,13 +1496,13 @@ class AccountInternal extends PureComponent<for (const id of scheduleIds) {await send('schedule/post-transaction', { id });}- this.refetchTransactions();+ void this.refetchTransactions();break;case 'post-transaction-today':for (const id of scheduleIds) {await send('schedule/post-transaction', { id, today: true });}- this.refetchTransactions();+ void this.refetchTransactions();break;case 'skip':for (const id of scheduleIds) {@@ -1642,7 +1647,7 @@ class AccountInternal extends PureComponent<// called directly from UI by sorting a column.// active filters need to be applied before sortingcase isFiltered:- this.applyFilters([...filterConditions]);+ void this.applyFilters([...filterConditions]);sortCurrentQuery(this, sortField, sortAscDesc);break;diff --git a/packages/desktop-client/src/components/accounts/AccountSyncCheck.tsx b/packages/desktop-client/src/components/accounts/AccountSyncCheck.tsxindex ca147e0d5b..9d78ad4734 100644--- a/packages/desktop-client/src/components/accounts/AccountSyncCheck.tsx+++ b/packages/desktop-client/src/components/accounts/AccountSyncCheck.tsx@@ -99,7 +99,7 @@ export function AccountSyncCheck() {setOpen(false);if (acc.account_id) {- authorizeBank(dispatch);+ void authorizeBank(dispatch);}},[dispatch],diff --git a/packages/desktop-client/src/components/admin/UserAccess/UserAccess.tsx b/packages/desktop-client/src/components/admin/UserAccess/UserAccess.tsxindex 2fd540d1f0..97edc76918 100644--- a/packages/desktop-client/src/components/admin/UserAccess/UserAccess.tsx+++ b/packages/desktop-client/src/components/admin/UserAccess/UserAccess.tsx@@ -108,7 +108,7 @@ function UserAccessContent({ isModal }: ManageUserAccessContentProps) {}}- loadData();+ void loadData();return () => {undo.setUndoState('openModal', null);diff --git a/packages/desktop-client/src/components/admin/UserAccess/UserAccessRow.tsx b/packages/desktop-client/src/components/admin/UserAccess/UserAccessRow.tsxindex b8ddeda905..478c7302b0 100644--- a/packages/desktop-client/src/components/admin/UserAccess/UserAccessRow.tsx+++ b/packages/desktop-client/src/components/admin/UserAccess/UserAccessRow.tsx@@ -81,7 +81,7 @@ export const UserAccessRow = memo(button: {title: t('Go to login'),action: () => {- dispatch(signOut());+ void dispatch(signOut());},},},diff --git a/packages/desktop-client/src/components/admin/UserDirectory/UserDirectory.tsx b/packages/desktop-client/src/components/admin/UserDirectory/UserDirectory.tsxindex d73d168c76..864636020d 100644--- a/packages/desktop-client/src/components/admin/UserDirectory/UserDirectory.tsx+++ b/packages/desktop-client/src/components/admin/UserDirectory/UserDirectory.tsx@@ -135,7 +135,7 @@ function UserDirectoryContent({ isModal }: ManageUserDirectoryContentProps) {await loadUsers();}- loadData();+ void loadData();return () => {undo.setUndoState('openModal', null);@@ -164,7 +164,7 @@ function UserDirectoryContent({ isModal }: ManageUserDirectoryContentProps) {button: {title: t('Go to login'),action: () => {- dispatch(signOut());+ void dispatch(signOut());},},},diff --git a/packages/desktop-client/src/components/banksync/EditSyncAccount.tsx b/packages/desktop-client/src/components/banksync/EditSyncAccount.tsxindex 43ccc93d9f..5a2ea59c1e 100644--- a/packages/desktop-client/src/components/banksync/EditSyncAccount.tsx+++ b/packages/desktop-client/src/components/banksync/EditSyncAccount.tsx@@ -246,7 +246,7 @@ export function EditSyncAccount({ account }: EditSyncAccountProps) {<Buttonstyle={{ color: theme.errorText }}onPress={() => {- onUnlink(close);+ void onUnlink(close);}}><Trans>Unlink account</Trans>@@ -259,7 +259,7 @@ export function EditSyncAccount({ account }: EditSyncAccountProps) {<Buttonvariant="primary"onPress={() => {- onSave(close);+ void onSave(close);}}><Trans>Save</Trans>diff --git a/packages/desktop-client/src/components/budget/index.tsx b/packages/desktop-client/src/components/budget/index.tsxindex 008edfe2ab..7fc984a0c0 100644--- a/packages/desktop-client/src/components/budget/index.tsx+++ b/packages/desktop-client/src/components/budget/index.tsx@@ -71,12 +71,12 @@ export function Budget() {setInitialized(true);}- run();+ void run();});useEffect(() => init(), []);const loadBoundBudgets = useEffectEvent(() => {- send('get-budget-bounds').then(({ start, end }) => {+ void send('get-budget-bounds').then(({ start, end }) => {if (bounds.start !== start || bounds.end !== end) {setBounds({ start, end });}@@ -141,7 +141,7 @@ export function Budget() {type: 'date',},];- navigate('/accounts', {+ void navigate('/accounts', {state: {goBack: true,filterConditions,diff --git a/packages/desktop-client/src/components/common/Link.tsx b/packages/desktop-client/src/components/common/Link.tsxindex 232202f0c3..6844aef780 100644--- a/packages/desktop-client/src/components/common/Link.tsx+++ b/packages/desktop-client/src/components/common/Link.tsx@@ -106,7 +106,7 @@ const ButtonLink = ({ to, style, activeStyle, ...props }: ButtonLinkProps) => {variant={props.buttonVariant}onPress={e => {props.onPress?.(e);- navigate(path);+ void navigate(path);}}/>);diff --git a/packages/desktop-client/src/components/formula/QueryManager.tsx b/packages/desktop-client/src/components/formula/QueryManager.tsxindex eda8dadbbb..47748277a8 100644--- a/packages/desktop-client/src/components/formula/QueryManager.tsx+++ b/packages/desktop-client/src/components/formula/QueryManager.tsx@@ -298,7 +298,7 @@ function QueryItem({setAllMonths(allMonths);}- run();+ void run();}, [locale]);const filters = useRuleConditionFilters(diff --git a/packages/desktop-client/src/components/manager/BudgetFileSelection.tsx b/packages/desktop-client/src/components/manager/BudgetFileSelection.tsxindex 8955a079b2..f886790e35 100644--- a/packages/desktop-client/src/components/manager/BudgetFileSelection.tsx+++ b/packages/desktop-client/src/components/manager/BudgetFileSelection.tsx@@ -270,7 +270,7 @@ type BudgetFileListItemProps = ComponentPropsWithoutRef<typeof GridListItem<File>> & {quickSwitchMode: boolean;- onSelect: (file: File) => void;+ onSelect: (file: File) => Promise<void>;onDelete: (file: File) => void;onDuplicate: (file: File) => void;currentUserId: string;@@ -379,7 +379,7 @@ function BudgetFileListItem({type BudgetFileListProps = {files: File[];quickSwitchMode: boolean;- onSelect: (file: File) => void;+ onSelect: (file: File) => Promise<void>;onDelete: (file: File) => void;onDuplicate: (file: File) => void;currentUserId: string;@@ -447,7 +447,7 @@ function RefreshButton({ style, onRefresh }: RefreshButtonProps) {async function _onRefresh() {setLoading(true);- await onRefresh();+ onRefresh();setLoading(false);}@@ -556,7 +556,7 @@ export function BudgetFileSelection({useEffect(() => {if (multiuserEnabled && !userData?.offline) {- fetchUsers();+ void fetchUsers();}}, [multiuserEnabled, userData?.offline, fetchUsers]);@@ -583,13 +583,13 @@ export function BudgetFileSelection({const onCreate = ({ testMode = false } = {}) => {if (!creating) {setCreating(true);- dispatch(createBudget({ testMode }));+ void dispatch(createBudget({ testMode }));}};const refresh = () => {- dispatch(getUserData());- dispatch(loadAllFiles());+ void dispatch(getUserData());+ void dispatch(loadAllFiles());};const initialMount = useInitialMount();diff --git a/packages/desktop-client/src/components/manager/ConfigServer.tsx b/packages/desktop-client/src/components/manager/ConfigServer.tsxindex e4b7e107c1..fa8f11f8dd 100644--- a/packages/desktop-client/src/components/manager/ConfigServer.tsx+++ b/packages/desktop-client/src/components/manager/ConfigServer.tsx@@ -88,9 +88,9 @@ export function ElectronServerConfig({await window.globalThis.Actual.stopSyncServer();await window.globalThis.Actual.startSyncServer();setStartingSyncServer(false);- initElectronSyncServerRunningStatus();+ void initElectronSyncServerRunningStatus();await setServerUrl(`http://localhost:${electronServerPort}`);- navigate('/');+ void navigate('/');} catch (error) {setStartingSyncServer(false);setConfigError(t('Failed to configure sync server'));@@ -108,7 +108,7 @@ export function ElectronServerConfig({};useEffect(() => {- initElectronSyncServerRunningStatus();+ void initElectronSyncServerRunningStatus();}, []);async function dontUseSyncServer() {@@ -344,7 +344,7 @@ export function ConfigServer() {} else {setLoading(false);await dispatch(signOut());- navigate('/');+ void navigate('/');}}@@ -371,13 +371,13 @@ export function ConfigServer() {async function onSkip() {await setServerUrl(null);await dispatch(loggedIn());- navigate('/');+ void navigate('/');}async function onCreateTestFile() {await setServerUrl(null);await dispatch(createBudget({ testMode: true }));- navigate('/');+ void navigate('/');}const [syncServerConfig] = useGlobalPref('syncServerConfig');@@ -542,7 +542,7 @@ export function ConfigServer() {style={{ marginLeft: 15 }}onPress={async () => {await onCreateTestFile();- navigate('/');+ void navigate('/');}}><Trans>Create test file</Trans>diff --git a/packages/desktop-client/src/components/manager/ManagementApp.tsx b/packages/desktop-client/src/components/manager/ManagementApp.tsxindex b75585d705..3480830251 100644--- a/packages/desktop-client/src/components/manager/ManagementApp.tsx+++ b/packages/desktop-client/src/components/manager/ManagementApp.tsx@@ -88,7 +88,7 @@ export function ManagementApp() {dispatch(setAppState({ managerHasInitialized: true }));}- fetchData();+ void fetchData();}, [dispatch]);return (diff --git a/packages/desktop-client/src/components/manager/subscribe/Bootstrap.tsx b/packages/desktop-client/src/components/manager/subscribe/Bootstrap.tsxindex e22e38bc5d..cdf875120b 100644--- a/packages/desktop-client/src/components/manager/subscribe/Bootstrap.tsx+++ b/packages/desktop-client/src/components/manager/subscribe/Bootstrap.tsx@@ -55,7 +55,7 @@ export function Bootstrap() {setError(error);} else {await refreshLoginMethods();- navigate('/login');+ void navigate('/login');}}diff --git a/packages/desktop-client/src/components/manager/subscribe/ChangePassword.tsx b/packages/desktop-client/src/components/manager/subscribe/ChangePassword.tsxindex fe8e4976ed..fd5c674088 100644--- a/packages/desktop-client/src/components/manager/subscribe/ChangePassword.tsx+++ b/packages/desktop-client/src/components/manager/subscribe/ChangePassword.tsx@@ -43,7 +43,7 @@ export function ChangePassword() {} else {setMessage(t('Password successfully changed'));await send('subscribe-sign-in', { password });- navigate('/');+ void navigate('/');}}diff --git a/packages/desktop-client/src/components/manager/subscribe/Error.tsx b/packages/desktop-client/src/components/manager/subscribe/Error.tsxindex 1572185cd5..4b2541524c 100644--- a/packages/desktop-client/src/components/manager/subscribe/Error.tsx+++ b/packages/desktop-client/src/components/manager/subscribe/Error.tsx@@ -25,7 +25,7 @@ export function Error() {const { error } = (location.state || {}) as { error? };function onTryAgain() {- navigate('/');+ void navigate('/');}return (diff --git a/packages/desktop-client/src/components/manager/subscribe/Login.tsx b/packages/desktop-client/src/components/manager/subscribe/Login.tsxindex d363b281a8..bd63070c53 100644--- a/packages/desktop-client/src/components/manager/subscribe/Login.tsx+++ b/packages/desktop-client/src/components/manager/subscribe/Login.tsx@@ -108,12 +108,12 @@ function OpenIdLogin({ setError }) {if (error) {setError(error);} else {- navigate('/');+ void navigate('/');}}useEffect(() => {- send('owner-created').then(created => setWarnMasterCreation(!created));+ void send('owner-created').then(created => setWarnMasterCreation(!created));}, []);useEffect(() => {@@ -202,7 +202,7 @@ function OpenIdLogin({ setError }) {variant="bare"isDisabled={firstLoginPassword === '' && warnMasterCreation}onPress={() => {- send('get-openid-config', {+ void send('get-openid-config', {password: firstLoginPassword,}).then(config => {if ('error' in config) {@@ -259,7 +259,7 @@ function OpenIdLogin({ setError }) {</Button>,]}onSetOpenId={async config => {- onSetOpenId(config);+ void onSetOpenId(config);}}/></View>@@ -316,7 +316,7 @@ export function Login() {useEffect(() => {if (checked && !searchParams.has('error')) {- (async () => {+ void (async () => {if (method === 'header') {setError(null);const { error } = await send('subscribe-sign-in', {@@ -327,7 +327,7 @@ export function Login() {if (error) {setError(error);} else {- dispatch(loggedIn());+ void dispatch(loggedIn());}}})();diff --git a/packages/desktop-client/src/components/manager/subscribe/OpenIdCallback.ts b/packages/desktop-client/src/components/manager/subscribe/OpenIdCallback.tsindex 86be63a8c8..d5059955a0 100644--- a/packages/desktop-client/src/components/manager/subscribe/OpenIdCallback.ts+++ b/packages/desktop-client/src/components/manager/subscribe/OpenIdCallback.ts@@ -9,8 +9,8 @@ export function OpenIdCallback() {const dispatch = useDispatch();useEffect(() => {const token = new URLSearchParams(window.location.search).get('token');- send('subscribe-set-token', { token: token as string }).then(() => {- dispatch(loggedIn());+ void send('subscribe-set-token', { token: token as string }).then(() => {+ void dispatch(loggedIn());});});return null;diff --git a/packages/desktop-client/src/components/manager/subscribe/common.tsx b/packages/desktop-client/src/components/manager/subscribe/common.tsxindex 542144767b..ee3ecae997 100644--- a/packages/desktop-client/src/components/manager/subscribe/common.tsx+++ b/packages/desktop-client/src/components/manager/subscribe/common.tsx@@ -36,7 +36,7 @@ export function useBootstrapped(redirect = true) {const ensure = url => {if (location.pathname !== url) {if (redirect) {- navigate(url);+ void navigate(url);}} else {setChecked(true);@@ -56,7 +56,7 @@ export function useBootstrapped(redirect = true) {if ('error' in result || !result.hasServer) {console.log('error' in result && result.error);- navigate('/config-server');+ void navigate('/config-server');return;}@@ -76,7 +76,7 @@ export function useBootstrapped(redirect = true) {> = await send('subscribe-needs-bootstrap');if ('error' in result) {- navigate('/error', { state: { error: result.error } });+ void navigate('/error', { state: { error: result.error } });} else if (result.bootstrapped) {ensure(`/login`);@@ -89,7 +89,7 @@ export function useBootstrapped(redirect = true) {}}}- run();+ void run();}, [location,navigate,diff --git a/packages/desktop-client/src/components/mobile/accounts/AccountPage.tsx b/packages/desktop-client/src/components/mobile/accounts/AccountPage.tsxindex 948564ccfe..a520901be3 100644--- a/packages/desktop-client/src/components/mobile/accounts/AccountPage.tsx+++ b/packages/desktop-client/src/components/mobile/accounts/AccountPage.tsx@@ -141,7 +141,7 @@ function AccountHeader({ account }: { readonly account: AccountEntity }) {);const onCloseAccount = useCallback(() => {- dispatch(openAccountCloseModal({ accountId: account.id }));+ void dispatch(openAccountCloseModal({ accountId: account.id }));}, [account.id, dispatch]);const { mutate: reopenAccount } = useReopenAccountMutation();diff --git a/packages/desktop-client/src/components/mobile/accounts/AccountTransactions.tsx b/packages/desktop-client/src/components/mobile/accounts/AccountTransactions.tsxindex 8597ee9a8e..2095130a6e 100644--- a/packages/desktop-client/src/components/mobile/accounts/AccountTransactions.tsx+++ b/packages/desktop-client/src/components/mobile/accounts/AccountTransactions.tsx@@ -133,7 +133,7 @@ function TransactionListWithPreviews({const onOpenTransaction = useCallback((transaction: TransactionEntity) => {if (!isPreviewId(transaction.id)) {- navigate(`/transactions/${transaction.id}`);+ void navigate(`/transactions/${transaction.id}`);} else {dispatch(pushModal({diff --git a/packages/desktop-client/src/components/mobile/accounts/AccountsPage.tsx b/packages/desktop-client/src/components/mobile/accounts/AccountsPage.tsxindex 3f653b6503..0da3b60a85 100644--- a/packages/desktop-client/src/components/mobile/accounts/AccountsPage.tsx+++ b/packages/desktop-client/src/components/mobile/accounts/AccountsPage.tsx@@ -515,7 +515,7 @@ export function AccountsPage() {const onOpenAccount = useCallback((account: AccountEntity) => {- navigate(`/accounts/${account.id}`);+ void navigate(`/accounts/${account.id}`);},[navigate],);diff --git a/packages/desktop-client/src/components/mobile/accounts/AllAccountTransactions.tsx b/packages/desktop-client/src/components/mobile/accounts/AllAccountTransactions.tsxindex cd5c46eb89..d21cb6c131 100644--- a/packages/desktop-client/src/components/mobile/accounts/AllAccountTransactions.tsx+++ b/packages/desktop-client/src/components/mobile/accounts/AllAccountTransactions.tsx@@ -63,7 +63,7 @@ function TransactionListWithPreviews() {const onOpenTransaction = useCallback((transaction: TransactionEntity) => {if (!isPreviewId(transaction.id)) {- navigate(`/transactions/${transaction.id}`);+ void navigate(`/transactions/${transaction.id}`);} else {dispatch(pushModal({diff --git a/packages/desktop-client/src/components/mobile/accounts/OffBudgetAccountTransactions.tsx b/packages/desktop-client/src/components/mobile/accounts/OffBudgetAccountTransactions.tsxindex c9f37e5259..eede9d6ea6 100644--- a/packages/desktop-client/src/components/mobile/accounts/OffBudgetAccountTransactions.tsx+++ b/packages/desktop-client/src/components/mobile/accounts/OffBudgetAccountTransactions.tsx@@ -74,7 +74,7 @@ function TransactionListWithPreviews() {const onOpenTransaction = useCallback((transaction: TransactionEntity) => {if (!isPreviewId(transaction.id)) {- navigate(`/transactions/${transaction.id}`);+ void navigate(`/transactions/${transaction.id}`);} else {dispatch(pushModal({diff --git a/packages/desktop-client/src/components/mobile/accounts/OnBudgetAccountTransactions.tsx b/packages/desktop-client/src/components/mobile/accounts/OnBudgetAccountTransactions.tsxindex cd84243927..9ec2cb4928 100644--- a/packages/desktop-client/src/components/mobile/accounts/OnBudgetAccountTransactions.tsx+++ b/packages/desktop-client/src/components/mobile/accounts/OnBudgetAccountTransactions.tsx@@ -74,7 +74,7 @@ function TransactionListWithPreviews() {const onOpenTransaction = useCallback((transaction: TransactionEntity) => {if (!isPreviewId(transaction.id)) {- navigate(`/transactions/${transaction.id}`);+ void navigate(`/transactions/${transaction.id}`);} else {dispatch(pushModal({diff --git a/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncAccountEditPage.tsx b/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncAccountEditPage.tsxindex b65147a03f..074a2b9e35 100644--- a/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncAccountEditPage.tsx+++ b/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncAccountEditPage.tsx@@ -46,12 +46,12 @@ export function MobileBankSyncAccountEditPage() {} = useBankSyncAccountSettings(accountId!);const handleCancel = () => {- navigate('/bank-sync');+ void navigate('/bank-sync');};const handleSave = async () => {saveSettings();- navigate('/bank-sync');+ void navigate('/bank-sync');};const unlinkAccount = useUnlinkAccountMutation();diff --git a/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncPage.tsx b/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncPage.tsxindex 99335d1b0d..748f4464aa 100644--- a/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncPage.tsx+++ b/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncPage.tsx@@ -98,7 +98,7 @@ export function MobileBankSyncPage() {(account: AccountEntity, action: 'link' | 'edit') => {switch (action) {case 'edit':- navigate(`/bank-sync/account/${account.id}/edit`);+ void navigate(`/bank-sync/account/${account.id}/edit`);break;case 'link':dispatch(diff --git a/packages/desktop-client/src/components/mobile/budget/BudgetPage.tsx b/packages/desktop-client/src/components/mobile/budget/BudgetPage.tsxindex 5c9456d461..d6578653fa 100644--- a/packages/desktop-client/src/components/mobile/budget/BudgetPage.tsx+++ b/packages/desktop-client/src/components/mobile/budget/BudgetPage.tsx@@ -114,7 +114,7 @@ export function BudgetPage() {setInitialized(true);}- init();+ void init();}, [budgetType, startMonth, dispatch, spreadsheet]);const onBudgetAction = useCallback(@@ -479,7 +479,7 @@ export function BudgetPage() {);const onSwitchBudgetFile = useCallback(() => {- dispatch(closeBudget());+ void dispatch(closeBudget());}, [dispatch]);const onOpenBudgetMonthMenu = useCallback(@@ -587,7 +587,7 @@ export function BudgetPage() {<SheetNameProvider name={monthUtils.sheetForMonth(startMonth)}><SyncRefreshonSync={async () => {- dispatch(sync());+ void dispatch(sync());}}>{({ onRefresh }) => (diff --git a/packages/desktop-client/src/components/mobile/budget/CategoryTransactions.tsx b/packages/desktop-client/src/components/mobile/budget/CategoryTransactions.tsxindex 6e79b1794b..14d77c68f7 100644--- a/packages/desktop-client/src/components/mobile/budget/CategoryTransactions.tsx+++ b/packages/desktop-client/src/components/mobile/budget/CategoryTransactions.tsx@@ -75,7 +75,7 @@ function TransactionListWithPreviews({(transaction: TransactionEntity) => {// details of how the native app used to handle preview transactions here can be found at commit 05e58279if (!isPreviewId(transaction.id)) {- navigate(`/transactions/${transaction.id}`);+ void navigate(`/transactions/${transaction.id}`);}},[navigate],diff --git a/packages/desktop-client/src/components/mobile/budget/ExpenseCategoryListItem.tsx b/packages/desktop-client/src/components/mobile/budget/ExpenseCategoryListItem.tsxindex 6d2b925e42..f9fffc87f1 100644--- a/packages/desktop-client/src/components/mobile/budget/ExpenseCategoryListItem.tsx+++ b/packages/desktop-client/src/components/mobile/budget/ExpenseCategoryListItem.tsx@@ -413,7 +413,7 @@ export function ExpenseCategoryListItem({if (!category) {return;}- navigate(`/categories/${category.id}?month=${month}`);+ void navigate(`/categories/${category.id}?month=${month}`);}, [category, month, navigate]);if (!category) {diff --git a/packages/desktop-client/src/components/mobile/budget/IncomeCategoryListItem.tsx b/packages/desktop-client/src/components/mobile/budget/IncomeCategoryListItem.tsxindex e84bcbe424..b328495924 100644--- a/packages/desktop-client/src/components/mobile/budget/IncomeCategoryListItem.tsx+++ b/packages/desktop-client/src/components/mobile/budget/IncomeCategoryListItem.tsx@@ -196,7 +196,7 @@ export function IncomeCategoryListItem({return null;}- navigate(`/categories/${category.id}?month=${month}`);+ void navigate(`/categories/${category.id}?month=${month}`);}, [category, month, navigate]);const onCarryover = useCallback(diff --git a/packages/desktop-client/src/components/mobile/budget/UncategorizedTransactions.tsx b/packages/desktop-client/src/components/mobile/budget/UncategorizedTransactions.tsxindex 64e4c15944..c628ab5c7e 100644--- a/packages/desktop-client/src/components/mobile/budget/UncategorizedTransactions.tsx+++ b/packages/desktop-client/src/components/mobile/budget/UncategorizedTransactions.tsx@@ -43,7 +43,7 @@ export function UncategorizedTransactions() {(transaction: TransactionEntity) => {// details of how the native app used to handle preview transactions here can be found at commit 05e58279if (!isPreviewId(transaction.id)) {- navigate(`/transactions/${transaction.id}`);+ void navigate(`/transactions/${transaction.id}`);}},[navigate],diff --git a/packages/desktop-client/src/components/mobile/payees/MobilePayeeEditPage.tsx b/packages/desktop-client/src/components/mobile/payees/MobilePayeeEditPage.tsxindex 10f22ed86d..9c83e38240 100644--- a/packages/desktop-client/src/components/mobile/payees/MobilePayeeEditPage.tsx+++ b/packages/desktop-client/src/components/mobile/payees/MobilePayeeEditPage.tsx@@ -43,13 +43,13 @@ export function MobilePayeeEditPage() {setIsLoading(false);} else {// Payee not found, navigate back to payees list- navigate('/payees');+ void navigate('/payees');}}}, [id, payees, navigate]);const handleCancel = useCallback(() => {- navigate(-1);+ void navigate(-1);}, [navigate]);const handleSave = useCallback(async () => {@@ -67,7 +67,7 @@ export function MobilePayeeEditPage() {newName: editedPayeeName.trim(),}),});- navigate('/payees');+ void navigate('/payees');} catch (error) {console.error('Failed to update payee:', error);dispatch(diff --git a/packages/desktop-client/src/components/mobile/payees/MobilePayeesPage.tsx b/packages/desktop-client/src/components/mobile/payees/MobilePayeesPage.tsxindex 632875391c..f9c575bc6b 100644--- a/packages/desktop-client/src/components/mobile/payees/MobilePayeesPage.tsx+++ b/packages/desktop-client/src/components/mobile/payees/MobilePayeesPage.tsx@@ -42,7 +42,7 @@ export function MobilePayeesPage() {const handlePayeePress = useCallback((payee: PayeeEntity) => {- navigate(`/payees/${payee.id}`);+ void navigate(`/payees/${payee.id}`);},[navigate],);@@ -56,18 +56,18 @@ export function MobilePayeesPage() {id: payee.id,});const ruleIds = associatedRules.map(rule => rule.id).join(',');- navigate(`/rules?visible-rules=${ruleIds}`);+ void navigate(`/rules?visible-rules=${ruleIds}`);return;} catch (error) {console.error('Failed to fetch payee rules:', error);// Fallback to general rules page- navigate('/rules');+ void navigate('/rules');return;}}// Create a new rule for the payee- navigate('/rules/new', {+ void navigate('/rules/new', {state: {rule: {conditions: [diff --git a/packages/desktop-client/src/components/mobile/rules/AddRuleButton.tsx b/packages/desktop-client/src/components/mobile/rules/AddRuleButton.tsxindex 6be024a607..fbab6199ae 100644--- a/packages/desktop-client/src/components/mobile/rules/AddRuleButton.tsx+++ b/packages/desktop-client/src/components/mobile/rules/AddRuleButton.tsx@@ -11,7 +11,7 @@ export function AddRuleButton() {const navigate = useNavigate();const handleAddRule = useCallback(() => {- navigate('/rules/new');+ void navigate('/rules/new');}, [navigate]);return (diff --git a/packages/desktop-client/src/components/mobile/rules/MobileRuleEditPage.tsx b/packages/desktop-client/src/components/mobile/rules/MobileRuleEditPage.tsxindex 4fe9eef1af..2e2aaa51df 100644--- a/packages/desktop-client/src/components/mobile/rules/MobileRuleEditPage.tsx+++ b/packages/desktop-client/src/components/mobile/rules/MobileRuleEditPage.tsx@@ -56,13 +56,13 @@ export function MobileRuleEditPage() {setRule(loadedRule);} else {// Rule not found, navigate back to rules list- navigate('/rules');+ void navigate('/rules');}}).catch(error => {console.error('Failed to load rule:', error);// Navigate back to rules list if rule not found- navigate('/rules');+ void navigate('/rules');}).finally(() => {setIsLoading(false);@@ -100,11 +100,11 @@ export function MobileRuleEditPage() {});}// Navigate back to rules list- navigate('/rules');+ void navigate('/rules');};const handleCancel = () => {- navigate(-1);+ void navigate(-1);};const handleDelete = () => {@@ -125,7 +125,7 @@ export function MobileRuleEditPage() {showUndoNotification({message: t('Rule deleted successfully'),});- navigate('/rules');+ void navigate('/rules');} catch (error) {console.error('Failed to delete rule:', error);dispatch(diff --git a/packages/desktop-client/src/components/mobile/rules/MobileRulesPage.tsx b/packages/desktop-client/src/components/mobile/rules/MobileRulesPage.tsxindex 365dc622f5..58ed7322d2 100644--- a/packages/desktop-client/src/components/mobile/rules/MobileRulesPage.tsx+++ b/packages/desktop-client/src/components/mobile/rules/MobileRulesPage.tsx@@ -94,13 +94,13 @@ export function MobileRulesPage() {}, []);useEffect(() => {- loadRules();+ void loadRules();}, [loadRules]);// Listen for undo events to refresh rules listuseEffect(() => {const onUndo = () => {- loadRules();+ void loadRules();};const lastUndoEvent = undo.getUndoState('undoEvent');@@ -113,7 +113,7 @@ export function MobileRulesPage() {const handleRulePress = useCallback((rule: RuleEntity) => {- navigate(`/rules/${rule.id}`);+ void navigate(`/rules/${rule.id}`);},[navigate],);diff --git a/packages/desktop-client/src/components/mobile/schedules/AddScheduleButton.tsx b/packages/desktop-client/src/components/mobile/schedules/AddScheduleButton.tsxindex 37d55fe4be..c1961b45aa 100644--- a/packages/desktop-client/src/components/mobile/schedules/AddScheduleButton.tsx+++ b/packages/desktop-client/src/components/mobile/schedules/AddScheduleButton.tsx@@ -11,7 +11,7 @@ export function AddScheduleButton() {const navigate = useNavigate();const handleAddSchedule = useCallback(() => {- navigate('/schedules/new');+ void navigate('/schedules/new');}, [navigate]);return (diff --git a/packages/desktop-client/src/components/mobile/schedules/MobileScheduleEditPage.tsx b/packages/desktop-client/src/components/mobile/schedules/MobileScheduleEditPage.tsxindex 532e411ef2..0acc89ea11 100644--- a/packages/desktop-client/src/components/mobile/schedules/MobileScheduleEditPage.tsx+++ b/packages/desktop-client/src/components/mobile/schedules/MobileScheduleEditPage.tsx@@ -126,11 +126,11 @@ export function MobileScheduleEditPage() {});// Navigate back to schedules list- navigate('/schedules');+ void navigate('/schedules');}async function onEditRule(ruleId: string) {- navigate(`/rules/${ruleId}`);+ void navigate(`/rules/${ruleId}`);}async function onLinkTransactions(ids: string[], scheduleId?: string) {diff --git a/packages/desktop-client/src/components/mobile/schedules/MobileSchedulesPage.tsx b/packages/desktop-client/src/components/mobile/schedules/MobileSchedulesPage.tsxindex cc5360296a..d442c17fe8 100644--- a/packages/desktop-client/src/components/mobile/schedules/MobileSchedulesPage.tsx+++ b/packages/desktop-client/src/components/mobile/schedules/MobileSchedulesPage.tsx@@ -90,7 +90,7 @@ export function MobileSchedulesPage() {const handleSchedulePress = useCallback((schedule: ScheduleEntity) => {- navigate(`/schedules/${schedule.id}`);+ void navigate(`/schedules/${schedule.id}`);},[navigate],);diff --git a/packages/desktop-client/src/components/mobile/transactions/AddTransactionButton.tsx b/packages/desktop-client/src/components/mobile/transactions/AddTransactionButton.tsxindex 7dbe638fd0..cc6bfc01d7 100644--- a/packages/desktop-client/src/components/mobile/transactions/AddTransactionButton.tsx+++ b/packages/desktop-client/src/components/mobile/transactions/AddTransactionButton.tsx@@ -25,7 +25,7 @@ export function AddTransactionButton({aria-label={t('Add transaction')}style={{ margin: 10 }}onPress={() => {- navigate(to, { state: { accountId, categoryId } });+ void navigate(to, { state: { accountId, categoryId } });}}><SvgAdd width={20} height={20} />diff --git a/packages/desktop-client/src/components/mobile/transactions/TransactionEdit.tsx b/packages/desktop-client/src/components/mobile/transactions/TransactionEdit.tsxindex fd4c6ed29d..7b87f7aa74 100644--- a/packages/desktop-client/src/components/mobile/transactions/TransactionEdit.tsx+++ b/packages/desktop-client/src/components/mobile/transactions/TransactionEdit.tsx@@ -683,7 +683,7 @@ const TransactionEditInner = memo<TransactionEditInnerProps>(}onSave(transactionsToSave);- navigate(-1);+ void navigate(-1);};const today = monthUtils.currentDay();@@ -741,7 +741,7 @@ const TransactionEditInner = memo<TransactionEditInnerProps>(},}),);- navigate(-1);+ void navigate(-1);},onCancel: onConfirmSave,},@@ -787,7 +787,7 @@ const TransactionEditInner = memo<TransactionEditInnerProps>(value: TransactionEntity[Field],) => {const newTransaction = { ...serializedTransaction, [name]: value };- await onUpdate(newTransaction, name);+ onUpdate(newTransaction, name);onClearActiveEdit();if (name === 'account') {@@ -800,7 +800,7 @@ const TransactionEditInner = memo<TransactionEditInnerProps>(const onTotalAmountUpdate = useCallback((value: number) => {if (transaction.amount !== value) {- onUpdateInner(transaction, 'amount', value);+ void onUpdateInner(transaction, 'amount', value);}},[onUpdateInner, transaction],@@ -836,7 +836,7 @@ const TransactionEditInner = memo<TransactionEditInnerProps>(unserializedTransaction.date,),onSelect: categoryId => {- onUpdateInner(transactionToEdit, name, categoryId);+ void onUpdateInner(transactionToEdit, name, categoryId);},onClose: () => {onClearActiveEdit();@@ -853,7 +853,7 @@ const TransactionEditInner = memo<TransactionEditInnerProps>(name: 'account-autocomplete',options: {onSelect: accountId => {- onUpdateInner(transactionToEdit, name, accountId);+ void onUpdateInner(transactionToEdit, name, accountId);},onClose: () => {onClearActiveEdit();@@ -870,7 +870,7 @@ const TransactionEditInner = memo<TransactionEditInnerProps>(name: 'payee-autocomplete',options: {onSelect: payeeId => {- onUpdateInner(transactionToEdit, name, payeeId);+ void onUpdateInner(transactionToEdit, name, payeeId);},onClose: () => {onClearActiveEdit();@@ -889,7 +889,7 @@ const TransactionEditInner = memo<TransactionEditInnerProps>(name,onSubmit: (name, value) => {if (typeof value === 'object' && 'useRegex' in value) {- onUpdateInner(+ void onUpdateInner(transactionToEdit,name,applyFindReplace(@@ -900,7 +900,7 @@ const TransactionEditInner = memo<TransactionEditInnerProps>(),);} else {- onUpdateInner(transactionToEdit, name, value);+ void onUpdateInner(transactionToEdit, name, value);}},onClose: () => {@@ -949,7 +949,7 @@ const TransactionEditInner = memo<TransactionEditInnerProps>(return;}- navigate(-1);+ void navigate(-1);},},},@@ -1360,7 +1360,7 @@ function TransactionEditUnconnected({}}if (transactionId !== 'new') {- fetchTransaction();+ void fetchTransaction();} else {isAdding.current = true;}@@ -1632,7 +1632,7 @@ function TransactionEditUnconnected({<Buttonvariant="primary"onPress={() => {- navigate('/budget');+ void navigate('/budget');}}><Trans>Go to budget</Trans>diff --git a/packages/desktop-client/src/components/mobile/transactions/TransactionList.tsx b/packages/desktop-client/src/components/mobile/transactions/TransactionList.tsxindex 0842d06f65..e1f8d32c05 100644--- a/packages/desktop-client/src/components/mobile/transactions/TransactionList.tsx+++ b/packages/desktop-client/src/components/mobile/transactions/TransactionList.tsx@@ -483,7 +483,7 @@ function SelectedTransactionsFloatingActionBar({getItemStyle={getMenuItemStyle}style={{ backgroundColor: theme.floatingActionBarBackground }}onMenuSelect={name => {- onBatchEdit?.({+ void onBatchEdit?.({name,ids: selectedTransactionsArray,onSuccess: (ids, name, value, mode) => {@@ -519,13 +519,13 @@ function SelectedTransactionsFloatingActionBar({[String(displayValue)]: () => {switch (name) {case 'account':- navigate(`/accounts/${value}`);+ void navigate(`/accounts/${value}`);break;case 'category':- navigate(`/categories/${value}`);+ void navigate(`/categories/${value}`);break;case 'payee':- navigate(`/payees`);+ void navigate(`/payees`);break;default:break;@@ -601,7 +601,7 @@ function SelectedTransactionsFloatingActionBar({style={{ backgroundColor: theme.floatingActionBarBackground }}onMenuSelect={type => {if (type === 'duplicate') {- onBatchDuplicate?.({+ void onBatchDuplicate?.({ids: selectedTransactionsArray,onSuccess: ids => {showUndoNotification({@@ -613,7 +613,7 @@ function SelectedTransactionsFloatingActionBar({},});} else if (type === 'link-schedule') {- onBatchLinkSchedule?.({+ void onBatchLinkSchedule?.({ids: selectedTransactionsArray,onSuccess: (ids, schedule) => {// TODO: When schedule becomes available in mobile, update undo notification message@@ -627,7 +627,7 @@ function SelectedTransactionsFloatingActionBar({},});} else if (type === 'unlink-schedule') {- onBatchUnlinkSchedule?.({+ void onBatchUnlinkSchedule?.({ids: selectedTransactionsArray,onSuccess: ids => {showUndoNotification({@@ -639,7 +639,7 @@ function SelectedTransactionsFloatingActionBar({},});} else if (type === 'delete') {- onBatchDelete?.({+ void onBatchDelete?.({ids: selectedTransactionsArray,onSuccess: ids => {showUndoNotification({@@ -652,7 +652,7 @@ function SelectedTransactionsFloatingActionBar({},});} else if (type === 'transfer') {- onSetTransfer?.(selectedTransactionsArray, payees, ids =>+ void onSetTransfer?.(selectedTransactionsArray, payees, ids =>showUndoNotification({message: t('Successfully marked {{count}} transactions as transfer.',@@ -663,7 +663,7 @@ function SelectedTransactionsFloatingActionBar({}),);} else if (type === 'merge') {- onMerge?.(selectedTransactionsArray, () =>+ void onMerge?.(selectedTransactionsArray, () =>showUndoNotification({message: t('Successfully merged transactions'),}),diff --git a/packages/desktop-client/src/components/modals/CreateAccountModal.tsx b/packages/desktop-client/src/components/modals/CreateAccountModal.tsxindex a6fe649480..8c67785d88 100644--- a/packages/desktop-client/src/components/modals/CreateAccountModal.tsx+++ b/packages/desktop-client/src/components/modals/CreateAccountModal.tsx@@ -65,9 +65,9 @@ export function CreateAccountModal({}if (upgradingAccountId == null) {- authorizeBank(dispatch);+ void authorizeBank(dispatch);} else {- authorizeBank(dispatch);+ void authorizeBank(dispatch);}};@@ -257,11 +257,11 @@ export function CreateAccountModal({};const onGoCardlessReset = () => {- send('secret-set', {+ void send('secret-set', {name: 'gocardless_secretId',value: null,}).then(() => {- send('secret-set', {+ void send('secret-set', {name: 'gocardless_secretKey',value: null,}).then(() => {@@ -271,11 +271,11 @@ export function CreateAccountModal({};const onSimpleFinReset = () => {- send('secret-set', {+ void send('secret-set', {name: 'simplefin_token',value: null,}).then(() => {- send('secret-set', {+ void send('secret-set', {name: 'simplefin_accessKey',value: null,}).then(() => {@@ -285,15 +285,15 @@ export function CreateAccountModal({};const onPluggyAiReset = () => {- send('secret-set', {+ void send('secret-set', {name: 'pluggyai_clientId',value: null,}).then(() => {- send('secret-set', {+ void send('secret-set', {name: 'pluggyai_clientSecret',value: null,}).then(() => {- send('secret-set', {+ void send('secret-set', {name: 'pluggyai_itemIds',value: null,}).then(() => {diff --git a/packages/desktop-client/src/components/modals/CreateEncryptionKeyModal.tsx b/packages/desktop-client/src/components/modals/CreateEncryptionKeyModal.tsxindex c9fb940dd4..6bbda48ddb 100644--- a/packages/desktop-client/src/components/modals/CreateEncryptionKeyModal.tsx+++ b/packages/desktop-client/src/components/modals/CreateEncryptionKeyModal.tsx@@ -60,9 +60,9 @@ export function CreateEncryptionKeyModal({return;}- dispatch(loadGlobalPrefs());- dispatch(loadAllFiles());- dispatch(sync());+ void dispatch(loadGlobalPrefs());+ void dispatch(loadAllFiles());+ void dispatch(sync());setLoading(false);close();@@ -174,7 +174,7 @@ export function CreateEncryptionKeyModal({<FormonSubmit={e => {e.preventDefault();- onCreateKey(close);+ void onCreateKey(close);}}><View style={{ alignItems: 'center' }}>diff --git a/packages/desktop-client/src/components/modals/CreateLocalAccountModal.tsx b/packages/desktop-client/src/components/modals/CreateLocalAccountModal.tsxindex 3a259ecc8b..2709041597 100644--- a/packages/desktop-client/src/components/modals/CreateLocalAccountModal.tsx+++ b/packages/desktop-client/src/components/modals/CreateLocalAccountModal.tsx@@ -75,7 +75,7 @@ export function CreateLocalAccountModal() {{onSuccess: id => {dispatch(closeModal());- navigate('/accounts/' + id);+ void navigate('/accounts/' + id);},},);diff --git a/packages/desktop-client/src/components/modals/EditAccess.tsx b/packages/desktop-client/src/components/modals/EditAccess.tsxindex 1825f4a91a..06dada014b 100644--- a/packages/desktop-client/src/components/modals/EditAccess.tsx+++ b/packages/desktop-client/src/components/modals/EditAccess.tsx@@ -41,20 +41,22 @@ export function EditUserAccess({const [availableUsers, setAvailableUsers] = useState<[string, string][]>([]);useEffect(() => {- send('access-get-available-users', defaultUserAccess.fileId).then(data => {- if ('error' in data) {- setSetError(data.error);- } else {- setAvailableUsers(- data.map(user => [- user.userId,- user.displayName- ? `${user.displayName} (${user.userName})`- : user.userName,- ]),- );- }- });+ void send('access-get-available-users', defaultUserAccess.fileId).then(+ data => {+ if ('error' in data) {+ setSetError(data.error);+ } else {+ setAvailableUsers(+ data.map(user => [+ user.userId,+ user.displayName+ ? `${user.displayName} (${user.userName})`+ : user.userName,+ ]),+ );+ }+ },+ );}, [defaultUserAccess.fileId]);async function onSave(close: () => void) {@@ -80,7 +82,7 @@ export function EditUserAccess({button: {title: t('Go to login'),action: () => {- dispatch(signOut());+ void dispatch(signOut());},},},diff --git a/packages/desktop-client/src/components/modals/EditUser.tsx b/packages/desktop-client/src/components/modals/EditUser.tsxindex ad69e875be..c640da4e05 100644--- a/packages/desktop-client/src/components/modals/EditUser.tsx+++ b/packages/desktop-client/src/components/modals/EditUser.tsx@@ -102,7 +102,7 @@ function useSaveUser() {button: {title: t('Go to login'),action: () => {- dispatch(signOut());+ void dispatch(signOut());},},},diff --git a/packages/desktop-client/src/components/modals/EnvelopeBudgetSummaryModal.tsx b/packages/desktop-client/src/components/modals/EnvelopeBudgetSummaryModal.tsxindex 404bf55da6..69175fbfe4 100644--- a/packages/desktop-client/src/components/modals/EnvelopeBudgetSummaryModal.tsx+++ b/packages/desktop-client/src/components/modals/EnvelopeBudgetSummaryModal.tsx@@ -66,7 +66,7 @@ export function EnvelopeBudgetSummaryModal({month,amount: sheetValue,onSubmit: (amount, toCategoryId) => {- onBudgetAction(month, 'transfer-available', {+ void onBudgetAction(month, 'transfer-available', {amount,month,category: toCategoryId,@@ -96,7 +96,7 @@ export function EnvelopeBudgetSummaryModal({showToBeBudgeted: false,amount: sheetValue,onSubmit: (amount, categoryId) => {- onBudgetAction(month, 'cover-overbudgeted', {+ void onBudgetAction(month, 'cover-overbudgeted', {category: categoryId,amount,currencyCode: format.currency.code,@@ -122,7 +122,7 @@ export function EnvelopeBudgetSummaryModal({options: {month,onSubmit: amount => {- onBudgetAction(month, 'hold', { amount });+ void onBudgetAction(month, 'hold', { amount });dispatch(collapseModals({ rootModalName: 'hold-buffer' }));},},@@ -132,7 +132,7 @@ export function EnvelopeBudgetSummaryModal({};const onResetHoldBuffer = () => {- onBudgetAction(month, 'reset-hold');+ void onBudgetAction(month, 'reset-hold');};const onClick = ({ close }: { close: () => void }) => {diff --git a/packages/desktop-client/src/components/modals/FixEncryptionKeyModal.tsx b/packages/desktop-client/src/components/modals/FixEncryptionKeyModal.tsxindex 5bbd17a682..0d5dedc372 100644--- a/packages/desktop-client/src/components/modals/FixEncryptionKeyModal.tsx+++ b/packages/desktop-client/src/components/modals/FixEncryptionKeyModal.tsx@@ -111,7 +111,7 @@ export function FixEncryptionKeyModal({<FormonSubmit={e => {e.preventDefault();- onUpdateKey(close);+ void onUpdateKey(close);}}><Viewdiff --git a/packages/desktop-client/src/components/modals/GoCardlessExternalMsgModal.tsx b/packages/desktop-client/src/components/modals/GoCardlessExternalMsgModal.tsxindex 19b2458b0d..828704ace5 100644--- a/packages/desktop-client/src/components/modals/GoCardlessExternalMsgModal.tsx+++ b/packages/desktop-client/src/components/modals/GoCardlessExternalMsgModal.tsx@@ -60,7 +60,7 @@ function useAvailableBanks(country: string) {setIsLoading(false);}- fetch();+ void fetch();}, [setBanks, setIsLoading, country]);return {diff --git a/packages/desktop-client/src/components/modals/GoCardlessInitialiseModal.tsx b/packages/desktop-client/src/components/modals/GoCardlessInitialiseModal.tsxindex d925861217..e814ae5f62 100644--- a/packages/desktop-client/src/components/modals/GoCardlessInitialiseModal.tsx+++ b/packages/desktop-client/src/components/modals/GoCardlessInitialiseModal.tsx@@ -142,7 +142,7 @@ export const GoCardlessInitialiseModal = ({variant="primary"isLoading={isLoading}onPress={() => {- onSubmit(close);+ void onSubmit(close);}}><Trans>Save and continue</Trans>diff --git a/packages/desktop-client/src/components/modals/ImportTransactionsModal/ImportTransactionsModal.tsx b/packages/desktop-client/src/components/modals/ImportTransactionsModal/ImportTransactionsModal.tsxindex 7d177f6996..c42f70bf11 100644--- a/packages/desktop-client/src/components/modals/ImportTransactionsModal/ImportTransactionsModal.tsx+++ b/packages/desktop-client/src/components/modals/ImportTransactionsModal/ImportTransactionsModal.tsx@@ -413,7 +413,7 @@ export function ImportTransactionsModal({importNotes,});- parse(originalFileName, parseOptions);+ void parse(originalFileName, parseOptions);}, [originalFileName,delimiter,@@ -471,7 +471,7 @@ export function ImportTransactionsModal({importNotes,});- parse(res[0], parseOptions);+ void parse(res[0], parseOptions);}function onUpdateFields(field, name) {@@ -656,7 +656,7 @@ export function ImportTransactionsModal({{onSuccess: async didChange => {if (didChange) {- queryClient.invalidateQueries(payeeQueries.list());+ void queryClient.invalidateQueries(payeeQueries.list());}if (onImported) {@@ -749,7 +749,7 @@ export function ImportTransactionsModal({return;}- onImportPreview();+ void onImportPreview();}, [loadingState, parsedTransactions.length]);const headers: ComponentProps<typeof TableHeader>['headers'] = [@@ -1133,7 +1133,7 @@ export function ImportTransactionsModal({isDisabled={count === 0}isLoading={loadingState === 'importing'}onPress={() => {- onImport(close);+ void onImport(close);}}><Trans count={count}>Import {{ count }} transactions</Trans>diff --git a/packages/desktop-client/src/components/modals/LoadBackupModal.tsx b/packages/desktop-client/src/components/modals/LoadBackupModal.tsxindex cd5cc02849..190c239550 100644--- a/packages/desktop-client/src/components/modals/LoadBackupModal.tsx+++ b/packages/desktop-client/src/components/modals/LoadBackupModal.tsx@@ -69,7 +69,7 @@ export function LoadBackupModal({useEffect(() => {if (budgetIdToLoad) {- send('backups-get', { id: budgetIdToLoad }).then(setBackups);+ void send('backups-get', { id: budgetIdToLoad }).then(setBackups);}}, [budgetIdToLoad]);@@ -119,7 +119,7 @@ export function LoadBackupModal({variant="primary"onPress={() => {if (budgetIdToLoad && latestBackup.id) {- dispatch(+ void dispatch(loadBackup({budgetId: budgetIdToLoad,backupId: latestBackup.id,@@ -165,7 +165,7 @@ export function LoadBackupModal({backups={previousBackups}onSelect={id => {if (budgetIdToLoad && id) {- dispatch(+ void dispatch(loadBackup({ budgetId: budgetIdToLoad, backupId: id }),);}diff --git a/packages/desktop-client/src/components/modals/MergeUnusedPayeesModal.tsx b/packages/desktop-client/src/components/modals/MergeUnusedPayeesModal.tsxindex 46bae8edd5..02d9b83bb1 100644--- a/packages/desktop-client/src/components/modals/MergeUnusedPayeesModal.tsx+++ b/packages/desktop-client/src/components/modals/MergeUnusedPayeesModal.tsx@@ -197,7 +197,7 @@ export function MergeUnusedPayeesModal({autoFocusstyle={{ marginRight: 10 }}onPress={() => {- onMerge(targetPayee);+ void onMerge(targetPayee);close();}}>@@ -207,7 +207,7 @@ export function MergeUnusedPayeesModal({<Buttonstyle={{ marginRight: 10 }}onPress={() => {- onMergeAndCreateRule(targetPayee);+ void onMergeAndCreateRule(targetPayee);close();}}>diff --git a/packages/desktop-client/src/components/modals/OutOfSyncMigrationsModal.tsx b/packages/desktop-client/src/components/modals/OutOfSyncMigrationsModal.tsxindex 1e3445ed3a..a8145644ee 100644--- a/packages/desktop-client/src/components/modals/OutOfSyncMigrationsModal.tsx+++ b/packages/desktop-client/src/components/modals/OutOfSyncMigrationsModal.tsx@@ -21,7 +21,7 @@ export function OutOfSyncMigrationsModal() {const { t } = useTranslation();const closeBudgetAndModal = (close: () => void) => {- dispatch(closeBudget());+ void dispatch(closeBudget());close();};diff --git a/packages/desktop-client/src/components/modals/PluggyAiInitialiseModal.tsx b/packages/desktop-client/src/components/modals/PluggyAiInitialiseModal.tsxindex 8c8ceb153a..5def5de3ac 100644--- a/packages/desktop-client/src/components/modals/PluggyAiInitialiseModal.tsx+++ b/packages/desktop-client/src/components/modals/PluggyAiInitialiseModal.tsx@@ -180,7 +180,7 @@ export const PluggyAiInitialiseModal = ({variant="primary"isLoading={isLoading}onPress={() => {- onSubmit(close);+ void onSubmit(close);}}><Trans>Save and continue</Trans>diff --git a/packages/desktop-client/src/components/modals/SimpleFinInitialiseModal.tsx b/packages/desktop-client/src/components/modals/SimpleFinInitialiseModal.tsxindex fef7e54d18..f7c91c67b1 100644--- a/packages/desktop-client/src/components/modals/SimpleFinInitialiseModal.tsx+++ b/packages/desktop-client/src/components/modals/SimpleFinInitialiseModal.tsx@@ -106,7 +106,7 @@ export const SimpleFinInitialiseModal = ({autoFocusisLoading={isLoading}onPress={() => {- onSubmit(close);+ void onSubmit(close);}}><Trans>Save and continue</Trans>diff --git a/packages/desktop-client/src/components/modals/TransferOwnership.tsx b/packages/desktop-client/src/components/modals/TransferOwnership.tsxindex 9973384660..070e8ee3d5 100644--- a/packages/desktop-client/src/components/modals/TransferOwnership.tsx+++ b/packages/desktop-client/src/components/modals/TransferOwnership.tsx@@ -52,7 +52,7 @@ export function TransferOwnership({const [isTransferring, setIsTransferring] = useState(false);useEffect(() => {- send('users-get').then(+ void send('users-get').then((data: Awaited<ReturnType<Handlers['users-get']>>) => {if (!data) {setAvailableUsers([]);diff --git a/packages/desktop-client/src/components/modals/UnmigrateBudgetAutomationsModal.tsx b/packages/desktop-client/src/components/modals/UnmigrateBudgetAutomationsModal.tsxindex 6b1f669f89..35876b1377 100644--- a/packages/desktop-client/src/components/modals/UnmigrateBudgetAutomationsModal.tsx+++ b/packages/desktop-client/src/components/modals/UnmigrateBudgetAutomationsModal.tsx@@ -36,7 +36,7 @@ export function UnmigrateBudgetAutomationsModal({useEffect(() => {let mounted = true;- (async () => {+ void (async () => {try {const text: string = await send('budget/render-note-templates',diff --git a/packages/desktop-client/src/components/modals/manager/DuplicateFileModal.tsx b/packages/desktop-client/src/components/modals/manager/DuplicateFileModal.tsxindex 885059846c..901b13f9cc 100644--- a/packages/desktop-client/src/components/modals/manager/DuplicateFileModal.tsx+++ b/packages/desktop-client/src/components/modals/manager/DuplicateFileModal.tsx@@ -49,7 +49,7 @@ export function DuplicateFileModal({);useEffect(() => {- (async () => {+ void (async () => {setNewName(await uniqueBudgetName(file.name + fileEndingTranslation));})();}, [file.name, fileEndingTranslation]);diff --git a/packages/desktop-client/src/components/modals/manager/FilesSettingsModal.tsx b/packages/desktop-client/src/components/modals/manager/FilesSettingsModal.tsxindex 9a77893e3d..327b2dd717 100644--- a/packages/desktop-client/src/components/modals/manager/FilesSettingsModal.tsx+++ b/packages/desktop-client/src/components/modals/manager/FilesSettingsModal.tsx@@ -156,7 +156,7 @@ export function FilesSettingsModal() {const dispatch = useDispatch();function closeModal(close: () => void) {- dispatch(loadAllFiles());+ void dispatch(loadAllFiles());close();}diff --git a/packages/desktop-client/src/components/modals/manager/ImportActualModal.tsx b/packages/desktop-client/src/components/modals/manager/ImportActualModal.tsxindex 10afc8927f..17ccf0da29 100644--- a/packages/desktop-client/src/components/modals/manager/ImportActualModal.tsx+++ b/packages/desktop-client/src/components/modals/manager/ImportActualModal.tsx@@ -60,7 +60,7 @@ export function ImportActualModal() {setError(null);try {await dispatch(importBudget({ filepath: res[0], type: 'actual' }));- navigate('/budget');+ void navigate('/budget');} catch (err) {setError(err.message);} finally {diff --git a/packages/desktop-client/src/components/modals/manager/ImportYNAB4Modal.tsx b/packages/desktop-client/src/components/modals/manager/ImportYNAB4Modal.tsxindex 758b4bc7d6..c98e549fea 100644--- a/packages/desktop-client/src/components/modals/manager/ImportYNAB4Modal.tsx+++ b/packages/desktop-client/src/components/modals/manager/ImportYNAB4Modal.tsx@@ -44,7 +44,7 @@ export function ImportYNAB4Modal() {setError(null);try {await dispatch(importBudget({ filepath: res[0], type: 'ynab4' }));- navigate('/budget');+ void navigate('/budget');} catch (err) {setError(err.message);} finally {diff --git a/packages/desktop-client/src/components/modals/manager/ImportYNAB5Modal.tsx b/packages/desktop-client/src/components/modals/manager/ImportYNAB5Modal.tsxindex cd94a4c68e..555fcff340 100644--- a/packages/desktop-client/src/components/modals/manager/ImportYNAB5Modal.tsx+++ b/packages/desktop-client/src/components/modals/manager/ImportYNAB5Modal.tsx@@ -54,7 +54,7 @@ export function ImportYNAB5Modal() {setError(null);try {await dispatch(importBudget({ filepath: res[0], type: 'ynab5' }));- navigate('/budget');+ void navigate('/budget');} catch (err) {setError(err.message);} finally {diff --git a/packages/desktop-client/src/components/payees/ManagePayeesWithData.tsx b/packages/desktop-client/src/components/payees/ManagePayeesWithData.tsxindex ca6d6c0044..de7186622b 100644--- a/packages/desktop-client/src/components/payees/ManagePayeesWithData.tsx+++ b/packages/desktop-client/src/components/payees/ManagePayeesWithData.tsx@@ -69,7 +69,7 @@ export function ManagePayeesWithData({const lastUndoEvent = undo.getUndoState('undoEvent');if (lastUndoEvent) {- onUndo(lastUndoEvent);+ void onUndo(lastUndoEvent);}return listen('undo-event', onUndo);diff --git a/packages/desktop-client/src/components/payees/PayeeMenu.tsx b/packages/desktop-client/src/components/payees/PayeeMenu.tsxindex d01321fecc..1b8a88b500 100644--- a/packages/desktop-client/src/components/payees/PayeeMenu.tsx+++ b/packages/desktop-client/src/components/payees/PayeeMenu.tsx@@ -88,7 +88,7 @@ export function PayeeMenu({onDelete();break;case 'merge':- onMerge();+ void onMerge();break;case 'favorite':onFavorite();diff --git a/packages/desktop-client/src/components/reports/DashboardSelector.tsx b/packages/desktop-client/src/components/reports/DashboardSelector.tsxindex 422816816d..dd4d293be0 100644--- a/packages/desktop-client/src/components/reports/DashboardSelector.tsx+++ b/packages/desktop-client/src/components/reports/DashboardSelector.tsx@@ -35,7 +35,7 @@ export function DashboardSelector({{ name: defaultName },{onSuccess: id => {- navigate(`/reports/${id}`);+ void navigate(`/reports/${id}`);},},);@@ -97,9 +97,9 @@ export function DashboardSelector({slot="close"onMenuSelect={item => {if (item === 'add-new') {- handleAddDashboard();+ void handleAddDashboard();} else {- navigate(`/reports/${item}`);+ void navigate(`/reports/${item}`);}setMenuOpen(false);}}diff --git a/packages/desktop-client/src/components/reports/Overview.tsx b/packages/desktop-client/src/components/reports/Overview.tsxindex f0b5a4b050..c907049fa1 100644--- a/packages/desktop-client/src/components/reports/Overview.tsx+++ b/packages/desktop-client/src/components/reports/Overview.tsx@@ -308,7 +308,7 @@ export function Overview({ dashboard }: OverviewProps) {}),} satisfies ExportImportDashboard;- window.Actual.saveFile(+ void window.Actual.saveFile(JSON.stringify(data, null, 2),'dashboard.json',t('Export Dashboard'),@@ -442,7 +442,7 @@ export function Overview({ dashboard }: OverviewProps) {const nextDashboard = dashboardPages.find(d => d.id !== id);// NOTE: This should hold since invariant dashboard_pages > 1if (nextDashboard) {- navigate(`/reports/${nextDashboard.id}`);+ void navigate(`/reports/${nextDashboard.id}`);}},},@@ -533,7 +533,7 @@ export function Overview({ dashboard }: OverviewProps) {slot="close"onMenuSelect={item => {if (item === 'custom-report') {- navigate('/reports/custom');+ void navigate('/reports/custom');return;}@@ -658,16 +658,16 @@ export function Overview({ dashboard }: OverviewProps) {onMenuSelect={item => {switch (item) {case 'reset':- onResetDashboard();+ void onResetDashboard();break;case 'export':onExport();break;case 'import':- onImport();+ void onImport();break;case 'delete':- onDeleteDashboard(dashboard.id);+ void onDeleteDashboard(dashboard.id);break;default:throw new Error(diff --git a/packages/desktop-client/src/components/reports/ReportsDashboardRouter.tsx b/packages/desktop-client/src/components/reports/ReportsDashboardRouter.tsxindex 0c39da49c3..15bcb48c0b 100644--- a/packages/desktop-client/src/components/reports/ReportsDashboardRouter.tsx+++ b/packages/desktop-client/src/components/reports/ReportsDashboardRouter.tsx@@ -20,7 +20,7 @@ export function ReportsDashboardRouter() {// Redirect to first dashboard if no dashboardId in URLuseEffect(() => {if (!dashboardId && !isPending && dashboardPages.length > 0) {- navigate(`/reports/${dashboardPages[0].id}`, { replace: true });+ void navigate(`/reports/${dashboardPages[0].id}`, { replace: true });}}, [dashboardId, isPending, dashboardPages, navigate]);diff --git a/packages/desktop-client/src/components/reports/SaveReport.tsx b/packages/desktop-client/src/components/reports/SaveReport.tsxindex c30fa21547..5904f2d4b3 100644--- a/packages/desktop-client/src/components/reports/SaveReport.tsx+++ b/packages/desktop-client/src/components/reports/SaveReport.tsx@@ -217,7 +217,7 @@ export function SaveReport({case 'update-report':setErr('');setMenuOpen(false);- onAddUpdate({ menuChoice: item });+ void onAddUpdate({ menuChoice: item });break;case 'save-report':setErr('');diff --git a/packages/desktop-client/src/components/reports/graphs/showActivity.ts b/packages/desktop-client/src/components/reports/graphs/showActivity.tsindex a48d813742..c6ef291e75 100644--- a/packages/desktop-client/src/components/reports/graphs/showActivity.ts+++ b/packages/desktop-client/src/components/reports/graphs/showActivity.ts@@ -97,7 +97,7 @@ export function showActivity({type: 'id',},].filter(f => f);- navigate('/accounts', {+ void navigate('/accounts', {state: {goBack: true,filterConditions,diff --git a/packages/desktop-client/src/components/reports/reports/BudgetAnalysis.tsx b/packages/desktop-client/src/components/reports/reports/BudgetAnalysis.tsxindex 5badea9343..2d37668f81 100644--- a/packages/desktop-client/src/components/reports/reports/BudgetAnalysis.tsx+++ b/packages/desktop-client/src/components/reports/reports/BudgetAnalysis.tsx@@ -175,7 +175,7 @@ function BudgetAnalysisInternal({ widget }: BudgetAnalysisInternalProps) {setIsConcise(calculateIsConcise(liveStart, liveEnd));}}- run();+ void run();}, [locale, widget?.meta?.timeFrame]);const startDate = start + '-01';diff --git a/packages/desktop-client/src/components/reports/reports/Calendar.tsx b/packages/desktop-client/src/components/reports/reports/Calendar.tsxindex cfde66497a..c5c7f91405 100644--- a/packages/desktop-client/src/components/reports/reports/Calendar.tsx+++ b/packages/desktop-client/src/components/reports/reports/Calendar.tsx@@ -301,7 +301,7 @@ function CalendarInner({ widget, parameters }: CalendarInnerProps) {setAllMonths(allMonths);}- run();+ void run();}, [locale]);useEffect(() => {@@ -428,7 +428,7 @@ function CalendarInner({ widget, parameters }: CalendarInnerProps) {const onOpenTransaction = useCallback((transaction: TransactionEntity) => {- navigate(`/transactions/${transaction.id}`);+ void navigate(`/transactions/${transaction.id}`);},[navigate],);@@ -454,7 +454,7 @@ function CalendarInner({ widget, parameters }: CalendarInnerProps) {useEffect(() => {closeY.current = totalHeight;- api.start({+ void api.start({y: mobileTransactionsOpen ? openY : closeY.current,immediate: false,});@@ -462,7 +462,7 @@ function CalendarInner({ widget, parameters }: CalendarInnerProps) {const open = useCallback(({ canceled }: { canceled: boolean }) => {- api.start({+ void api.start({y: openY,immediate: false,config: canceled ? config.wobbly : config.stiff,@@ -474,7 +474,7 @@ function CalendarInner({ widget, parameters }: CalendarInnerProps) {const close = useCallback((velocity = 0) => {- api.start({+ void api.start({y: closeY.current,config: { ...config.stiff, velocity },});@@ -487,7 +487,7 @@ function CalendarInner({ widget, parameters }: CalendarInnerProps) {({ offset: [, oy], cancel }) => {if (oy < 0) {cancel();- api.start({ y: 0, immediate: true });+ void api.start({ y: 0, immediate: true });return;}@@ -501,7 +501,7 @@ function CalendarInner({ widget, parameters }: CalendarInnerProps) {open({ canceled: true });setMobileTransactionsOpen(true);} else {- api.start({ y: oy, immediate: true });+ void api.start({ y: oy, immediate: true });}}},diff --git a/packages/desktop-client/src/components/reports/reports/CalendarCard.tsx b/packages/desktop-client/src/components/reports/reports/CalendarCard.tsxindex b50f1d3c23..b2f834ba59 100644--- a/packages/desktop-client/src/components/reports/reports/CalendarCard.tsx+++ b/packages/desktop-client/src/components/reports/reports/CalendarCard.tsx@@ -76,7 +76,7 @@ export function CalendarCard({latestTrans ? latestTrans.date : monthUtils.currentDay(),);}- fetchLatestTransaction();+ void fetchLatestTransaction();}, []);const [start, end] = calculateTimeRange(@@ -487,7 +487,7 @@ function CalendarCardInner({marginBottom: 6,}}onPress={() => {- navigate(+ void navigate(`/reports/calendar/${widgetId}?month=${formatDate(calendar.start, 'yyyy-MM')}`,);}}@@ -562,11 +562,11 @@ function CalendarCardInner({isEditing={isEditing}onDayClick={date => {if (date) {- navigate(+ void navigate(`/reports/calendar/${widgetId}?day=${formatDate(date, 'yyyy-MM-dd')}`,);} else {- navigate(`/reports/calendar/${widgetId}`);+ void navigate(`/reports/calendar/${widgetId}`);}}}/>diff --git a/packages/desktop-client/src/components/reports/reports/CashFlow.tsx b/packages/desktop-client/src/components/reports/reports/CashFlow.tsxindex 6711417f2b..df3bf3893e 100644--- a/packages/desktop-client/src/components/reports/reports/CashFlow.tsx+++ b/packages/desktop-client/src/components/reports/reports/CashFlow.tsx@@ -163,7 +163,7 @@ function CashFlowInner({ widget }: CashFlowInnerProps) {setAllMonths(allMonths);}- run();+ void run();}, [locale]);useEffect(() => {diff --git a/packages/desktop-client/src/components/reports/reports/CashFlowCard.tsx b/packages/desktop-client/src/components/reports/reports/CashFlowCard.tsxindex ee8f216768..b55c6d580a 100644--- a/packages/desktop-client/src/components/reports/reports/CashFlowCard.tsx+++ b/packages/desktop-client/src/components/reports/reports/CashFlowCard.tsx@@ -125,7 +125,7 @@ export function CashFlowCard({latestTrans ? latestTrans.date : monthUtils.currentDay(),);}- fetchLatestTransaction();+ void fetchLatestTransaction();}, []);const [start, end] = calculateTimeRange(diff --git a/packages/desktop-client/src/components/reports/reports/Crossover.tsx b/packages/desktop-client/src/components/reports/reports/Crossover.tsxindex 0a51718ebf..b883e419eb 100644--- a/packages/desktop-client/src/components/reports/reports/Crossover.tsx+++ b/packages/desktop-client/src/components/reports/reports/Crossover.tsx@@ -197,7 +197,7 @@ function CrossoverInner({ widget }: CrossoverInnerProps) {setAllMonths(allMonths);}- run();+ void run();}, [locale]);useEffect(() => {diff --git a/packages/desktop-client/src/components/reports/reports/CrossoverCard.tsx b/packages/desktop-client/src/components/reports/reports/CrossoverCard.tsxindex 313b3db5a7..f0d824c155 100644--- a/packages/desktop-client/src/components/reports/reports/CrossoverCard.tsx+++ b/packages/desktop-client/src/components/reports/reports/CrossoverCard.tsx@@ -124,7 +124,7 @@ export function CrossoverCard({setEnd(end);}}- calculateDateRange();+ void calculateDateRange();return () => {isMounted = false;};diff --git a/packages/desktop-client/src/components/reports/reports/CustomReport.tsx b/packages/desktop-client/src/components/reports/reports/CustomReport.tsxindex 0555f31ddd..a1191e6fe3 100644--- a/packages/desktop-client/src/components/reports/reports/CustomReport.tsx+++ b/packages/desktop-client/src/components/reports/reports/CustomReport.tsx@@ -433,7 +433,7 @@ function CustomReportInner({ report: initialReport }: CustomReportInnerProps) {latestTransaction ? latestTransaction.date : monthUtils.currentDay(),);- onSetAllIntervals(earliestTransaction, latestTransaction, interval);+ void onSetAllIntervals(earliestTransaction, latestTransaction, interval);onSetStartAndEndDates(earliestTransaction,latestTransaction,@@ -443,7 +443,7 @@ function CustomReportInner({ report: initialReport }: CustomReportInnerProps) {);}- run();+ void run();}, [interval,dateRange,@@ -767,7 +767,7 @@ function CustomReportInner({ report: initialReport }: CustomReportInnerProps) {setReport(params.savedReport);if (params.savedReport.id !== initialReport?.id) {- navigate(`/reports/custom/${params.savedReport.id}`);+ void navigate(`/reports/custom/${params.savedReport.id}`);}break;case 'rename':@@ -798,14 +798,14 @@ function CustomReportInner({ report: initialReport }: CustomReportInnerProps) {setSavedStatus('saved');setReport(newReport);setReportData(newReport);- navigate(`/reports/custom/${newReport.id}`);+ void navigate(`/reports/custom/${newReport.id}`);break;default:}};const onBackClick = () => {- navigate('/reports');+ void navigate('/reports');};return (diff --git a/packages/desktop-client/src/components/reports/reports/CustomReportListCards.tsx b/packages/desktop-client/src/components/reports/reports/CustomReportListCards.tsxindex 3e292717d3..98e7138448 100644--- a/packages/desktop-client/src/components/reports/reports/CustomReportListCards.tsx+++ b/packages/desktop-client/src/components/reports/reports/CustomReportListCards.tsx@@ -104,7 +104,7 @@ function CustomReportListCardsInner({latestTrans ? latestTrans.date : monthUtils.currentDay(),);}- run();+ void run();}, []);const updateReportMutation = useUpdateReportMutation();diff --git a/packages/desktop-client/src/components/reports/reports/NetWorth.tsx b/packages/desktop-client/src/components/reports/reports/NetWorth.tsxindex e4f8eb1cb7..6a0bb6ff4b 100644--- a/packages/desktop-client/src/components/reports/reports/NetWorth.tsx+++ b/packages/desktop-client/src/components/reports/reports/NetWorth.tsx@@ -204,7 +204,7 @@ function NetWorthInner({ widget }: NetWorthInnerProps) {setAllMonths(allMonths);}- run();+ void run();}, [locale]);useEffect(() => {diff --git a/packages/desktop-client/src/components/reports/reports/NetWorthCard.tsx b/packages/desktop-client/src/components/reports/reports/NetWorthCard.tsxindex c50d07a463..8198328003 100644--- a/packages/desktop-client/src/components/reports/reports/NetWorthCard.tsx+++ b/packages/desktop-client/src/components/reports/reports/NetWorthCard.tsx@@ -66,7 +66,7 @@ export function NetWorthCard({latestTrans ? latestTrans.date : monthUtils.currentDay(),);}- fetchLatestTransaction();+ void fetchLatestTransaction();}, []);const [start, end] = calculateTimeRange(diff --git a/packages/desktop-client/src/components/reports/reports/Spending.tsx b/packages/desktop-client/src/components/reports/reports/Spending.tsxindex 19e4654f6a..a4acea58c7 100644--- a/packages/desktop-client/src/components/reports/reports/Spending.tsx+++ b/packages/desktop-client/src/components/reports/reports/Spending.tsx@@ -135,7 +135,7 @@ function SpendingInternal({ widget }: SpendingInternalProps) {setAllIntervals(allMonths);}- run();+ void run();}, [locale]);const getGraphData = useMemo(diff --git a/packages/desktop-client/src/components/reports/reports/Summary.tsx b/packages/desktop-client/src/components/reports/reports/Summary.tsxindex ed7cba2c1a..1534aafd4d 100644--- a/packages/desktop-client/src/components/reports/reports/Summary.tsx+++ b/packages/desktop-client/src/components/reports/reports/Summary.tsx@@ -210,7 +210,7 @@ function SummaryInner({ widget }: SummaryInnerProps) {setAllMonths(allMonths);}- run();+ void run();}, [locale]);useEffect(() => {diff --git a/packages/desktop-client/src/components/reports/reports/SummaryCard.tsx b/packages/desktop-client/src/components/reports/reports/SummaryCard.tsxindex c415dc1bee..70d995f4a6 100644--- a/packages/desktop-client/src/components/reports/reports/SummaryCard.tsx+++ b/packages/desktop-client/src/components/reports/reports/SummaryCard.tsx@@ -50,7 +50,7 @@ export function SummaryCard({latestTrans ? latestTrans.date : monthUtils.currentDay(),);}- fetchLatestTransaction();+ void fetchLatestTransaction();}, []);const [start, end] = calculateTimeRange(diff --git a/packages/desktop-client/src/components/reports/useReport.ts b/packages/desktop-client/src/components/reports/useReport.tsindex 255ec2815f..6e78f0fda7 100644--- a/packages/desktop-client/src/components/reports/useReport.ts+++ b/packages/desktop-client/src/components/reports/useReport.ts@@ -13,7 +13,7 @@ export function useReport<T>(const [results, setResults] = useState<T | null>(null);useEffect(() => {- getData(spreadsheet, results => setResults(results));+ void getData(spreadsheet, results => setResults(results));}, [getData, spreadsheet]);return results;}diff --git a/packages/desktop-client/src/components/rules/RuleEditor.tsx b/packages/desktop-client/src/components/rules/RuleEditor.tsxindex 7353cdfc42..c8b37e479a 100644--- a/packages/desktop-client/src/components/rules/RuleEditor.tsx+++ b/packages/desktop-client/src/components/rules/RuleEditor.tsx@@ -1056,7 +1056,7 @@ export function RuleEditor({setTransactions([]);}}- run();+ void run();}, [actionSplits, conditions, conditionsOp]);const selectedInst = useSelected('transactions', transactions, []);@@ -1215,7 +1215,7 @@ export function RuleEditor({const selectedTransactions = transactions.filter(({ id }) =>selectedInst.items.has(id),);- send('rule-apply-actions', {+ void send('rule-apply-actions', {transactions: selectedTransactions,actions: getUnparsedActions(actionSplits),}).then(content => {diff --git a/packages/desktop-client/src/components/schedules/DiscoverSchedules.tsx b/packages/desktop-client/src/components/schedules/DiscoverSchedules.tsxindex 28e235121f..49bda607a8 100644--- a/packages/desktop-client/src/components/schedules/DiscoverSchedules.tsx+++ b/packages/desktop-client/src/components/schedules/DiscoverSchedules.tsx@@ -247,7 +247,7 @@ export function DiscoverSchedules() {isLoading={creating}isDisabled={selectedInst.items.size === 0}onPress={() => {- onCreate();+ void onCreate();close();}}>diff --git a/packages/desktop-client/src/components/schedules/PostsOfflineNotification.tsx b/packages/desktop-client/src/components/schedules/PostsOfflineNotification.tsxindex 2d6ff13515..7b077b75f0 100644--- a/packages/desktop-client/src/components/schedules/PostsOfflineNotification.tsx+++ b/packages/desktop-client/src/components/schedules/PostsOfflineNotification.tsx@@ -98,7 +98,7 @@ export function PostsOfflineNotification() {variant="primary"autoFocusonPress={() => {- onPost();+ void onPost();close();}}>diff --git a/packages/desktop-client/src/components/schedules/ScheduleEditForm.tsx b/packages/desktop-client/src/components/schedules/ScheduleEditForm.tsxindex 7ccbe8ebd8..3788c15db5 100644--- a/packages/desktop-client/src/components/schedules/ScheduleEditForm.tsx+++ b/packages/desktop-client/src/components/schedules/ScheduleEditForm.tsx@@ -447,10 +447,10 @@ export function ScheduleEditForm({onSelect={(name, ids) => {switch (name) {case 'link':- onLinkTransactions(ids, schedule.id);+ void onLinkTransactions(ids, schedule.id);break;case 'unlink':- onUnlinkTransactions(ids);+ void onUnlinkTransactions(ids);break;default:}diff --git a/packages/desktop-client/src/components/schedules/ScheduleLink.tsx b/packages/desktop-client/src/components/schedules/ScheduleLink.tsxindex 43bf4e481a..bf31c40918 100644--- a/packages/desktop-client/src/components/schedules/ScheduleLink.tsx+++ b/packages/desktop-client/src/components/schedules/ScheduleLink.tsx@@ -124,7 +124,7 @@ export function ScheduleLink({style={{ marginLeft: 15, padding: '4px 10px' }}onPress={() => {close();- onCreate();+ void onCreate();}}><SvgAdd style={{ width: '20', padding: '3' }} />@@ -148,7 +148,7 @@ export function ScheduleLink({filter={filter}minimalonSelect={id => {- onSelect(id);+ void onSelect(id);close();}}schedules={schedules}diff --git a/packages/desktop-client/src/components/select/RecurringSchedulePicker.tsx b/packages/desktop-client/src/components/select/RecurringSchedulePicker.tsxindex 5d6f0976f6..12754aee16 100644--- a/packages/desktop-client/src/components/select/RecurringSchedulePicker.tsx+++ b/packages/desktop-client/src/components/select/RecurringSchedulePicker.tsx@@ -413,7 +413,7 @@ function RecurringScheduleTooltip({});setPreviewDates(error ? t('Invalid rule') : data);}- run();+ void run();}, [config, t]);if (previewDates == null) {diff --git a/packages/desktop-client/src/components/settings/Export.tsx b/packages/desktop-client/src/components/settings/Export.tsxindex bbcf842ae7..790d44e8a9 100644--- a/packages/desktop-client/src/components/settings/Export.tsx+++ b/packages/desktop-client/src/components/settings/Export.tsx@@ -34,7 +34,7 @@ export function ExportBudget() {}if (response.data) {- window.Actual.saveFile(+ void window.Actual.saveFile(response.data,`${format(new Date(), 'yyyy-MM-dd')}-${budgetName}.zip`,t('Export budget'),diff --git a/packages/desktop-client/src/components/settings/ThemeInstaller.tsx b/packages/desktop-client/src/components/settings/ThemeInstaller.tsxindex 5f35f9c9d4..695420770b 100644--- a/packages/desktop-client/src/components/settings/ThemeInstaller.tsx+++ b/packages/desktop-client/src/components/settings/ThemeInstaller.tsx@@ -166,7 +166,7 @@ export function ThemeInstaller({const handleInstallPastedCss = useCallback(() => {if (!pastedCss.trim()) return;- installTheme({+ void installTheme({css: pastedCss.trim(),name: t('Custom Theme'),repo: '',diff --git a/packages/desktop-client/src/components/settings/index.tsx b/packages/desktop-client/src/components/settings/index.tsxindex bbcef287b5..ffb5b3cd4c 100644--- a/packages/desktop-client/src/components/settings/index.tsx+++ b/packages/desktop-client/src/components/settings/index.tsx@@ -51,7 +51,7 @@ function About() {const versionInfo = useSelector(state => state.app.versionInfo);const [notifyWhenUpdateIsAvailable, setNotifyWhenUpdateIsAvailablePref] =useGlobalPref('notifyWhenUpdateIsAvailable', () => {- dispatch(getLatestAppVersion());+ void dispatch(getLatestAppVersion());});const dispatch = useDispatch();@@ -180,15 +180,15 @@ export function Settings() {const [_, setDefaultCurrencyCodePref] = useSyncedPref('defaultCurrencyCode');const onCloseBudget = () => {- dispatch(closeBudget());+ void dispatch(closeBudget());};useEffect(() => {const unlisten = listen('prefs-updated', () => {- dispatch(loadPrefs());+ void dispatch(loadPrefs());});- dispatch(loadPrefs());+ void dispatch(loadPrefs());return () => unlisten();}, [dispatch]);diff --git a/packages/desktop-client/src/components/sidebar/Account.tsx b/packages/desktop-client/src/components/sidebar/Account.tsxindex 50223c6ce6..85d8b18466 100644--- a/packages/desktop-client/src/components/sidebar/Account.tsx+++ b/packages/desktop-client/src/components/sidebar/Account.tsx@@ -258,7 +258,7 @@ export function Account<FieldName extends SheetFields<'account'>>({onMenuSelect={type => {switch (type) {case 'close': {- dispatch(+ void dispatch(openAccountCloseModal({ accountId: account.id }),);break;diff --git a/packages/desktop-client/src/components/sidebar/BudgetName.tsx b/packages/desktop-client/src/components/sidebar/BudgetName.tsxindex f4a5a1f036..6d3f87715f 100644--- a/packages/desktop-client/src/components/sidebar/BudgetName.tsx+++ b/packages/desktop-client/src/components/sidebar/BudgetName.tsx@@ -74,7 +74,7 @@ function EditableBudgetName() {setEditing(true);break;case 'settings':- navigate('/settings');+ void navigate('/settings');break;case 'loadBackup':if (isElectron()) {@@ -86,7 +86,7 @@ function EditableBudgetName() {}break;case 'close':- dispatch(closeBudget());+ void dispatch(closeBudget());break;default:}diff --git a/packages/desktop-client/src/components/sort.tsx b/packages/desktop-client/src/components/sort.tsxindex 2933c7c1ab..517f317036 100644--- a/packages/desktop-client/src/components/sort.tsx+++ b/packages/desktop-client/src/components/sort.tsx@@ -45,10 +45,10 @@ export function useDraggable<T>({const [, dragRef] = useDrag({type,item: () => {- _onDragChange.current({ state: 'start-preview', type, item });+ void _onDragChange.current({ state: 'start-preview', type, item });setTimeout(() => {- _onDragChange.current({ state: 'start' });+ void _onDragChange.current({ state: 'start' });}, 0);return { type, item };@@ -56,7 +56,7 @@ export function useDraggable<T>({collect: monitor => ({ isDragging: monitor.isDragging() }),end(dragState) {- _onDragChange.current({ state: 'end', type, item: dragState.item });+ void _onDragChange.current({ state: 'end', type, item: dragState.item });},canDrag() {@@ -103,7 +103,7 @@ export function useDroppable<T extends { id: string }>({>({accept: types,drop({ item }) {- onDrop(item.id, dropPos, id);+ void onDrop(item.id, dropPos, id);},hover(_, monitor) {if (!ref.current) return;diff --git a/packages/desktop-client/src/components/tags/TagRow.tsx b/packages/desktop-client/src/components/tags/TagRow.tsxindex 7cdc4b4af3..ef1b0181c4 100644--- a/packages/desktop-client/src/components/tags/TagRow.tsx+++ b/packages/desktop-client/src/components/tags/TagRow.tsx@@ -67,7 +67,7 @@ export const TagRow = memo(type: 'string',},];- navigate('/accounts', {+ void navigate('/accounts', {state: {goBack: true,filterConditions,diff --git a/packages/desktop-client/src/components/transactions/TransactionList.tsx b/packages/desktop-client/src/components/transactions/TransactionList.tsxindex dd92ba92cc..cbb3db6b12 100644--- a/packages/desktop-client/src/components/transactions/TransactionList.tsx+++ b/packages/desktop-client/src/components/transactions/TransactionList.tsx@@ -434,7 +434,7 @@ export function TransactionList({onRefetch();} else {onChange(changes.newTransaction, changes.data);- saveDiffAndApply(+ void saveDiffAndApply(changes.diff,changes,onChange,@@ -477,7 +477,7 @@ export function TransactionList({(id: TransactionEntity['id']) => {const changes = addSplitTransaction(transactionsLatest.current, id);onChange(changes.newTransaction, changes.data);- saveDiffAndApply(+ void saveDiffAndApply(changes.diff,changes,onChange,@@ -492,7 +492,7 @@ export function TransactionList({(id: TransactionEntity['id']) => {const changes = splitTransaction(transactionsLatest.current, id);onChange(changes.newTransaction, changes.data);- saveDiffAndApply(+ void saveDiffAndApply(changes.diff,changes,onChange,@@ -561,14 +561,17 @@ export function TransactionList({const onManagePayees = useCallback((id: PayeeEntity['id']) => {- navigate('/payees', id ? { state: { selectedPayee: id } } : undefined);+ void navigate(+ '/payees',+ id ? { state: { selectedPayee: id } } : undefined,+ );},[navigate],);const onNavigateToTransferAccount = useCallback((accountId: AccountEntity['id']) => {- navigate(`/accounts/${accountId}`);+ void navigate(`/accounts/${accountId}`);},[navigate],);diff --git a/packages/desktop-client/src/global-events.ts b/packages/desktop-client/src/global-events.tsindex 0e2ce4596c..835b0534d1 100644--- a/packages/desktop-client/src/global-events.ts+++ b/packages/desktop-client/src/global-events.ts@@ -70,7 +70,7 @@ export function handleGlobalEvents(store: AppStore, queryClient: QueryClient) {tables.includes('payees') ||tables.includes('payee_mapping')) {- queryClient.invalidateQueries({+ void queryClient.invalidateQueries({queryKey: payeeQueries.lists(),});}@@ -86,7 +86,7 @@ export function handleGlobalEvents(store: AppStore, queryClient: QueryClient) {const tagged = undo.getTaggedState(undoTag);if (tagged) {- Promise.all(promises).then(() => {+ void Promise.all(promises).then(() => {undo.setUndoState('undoEvent', undoState);// If a modal has been tagged, open it instead of navigating@@ -106,7 +106,7 @@ export function handleGlobalEvents(store: AppStore, queryClient: QueryClient) {window.location.href.replace(window.location.origin, '') !==tagged.url) {- window.__navigate(tagged.url);+ void window.__navigate(tagged.url);// This stops propagation of the undo event, which is// important because if we are changing URLs any existing// undo listeners on the current page don't need to be run@@ -134,33 +134,33 @@ export function handleGlobalEvents(store: AppStore, queryClient: QueryClient) {});const unlistenStartLoad = listen('start-load', () => {- store.dispatch(closeBudgetUI());+ void store.dispatch(closeBudgetUI());store.dispatch(setAppState({ loadingText: '' }));});const unlistenFinishLoad = listen('finish-load', () => {store.dispatch(closeModal());store.dispatch(setAppState({ loadingText: null }));- store.dispatch(loadPrefs());+ void store.dispatch(loadPrefs());});const unlistenStartImport = listen('start-import', () => {- store.dispatch(closeBudgetUI());+ void store.dispatch(closeBudgetUI());});const unlistenFinishImport = listen('finish-import', () => {store.dispatch(closeModal());store.dispatch(setAppState({ loadingText: null }));- store.dispatch(loadPrefs());+ void store.dispatch(loadPrefs());});const unlistenShowBudgets = listen('show-budgets', () => {- store.dispatch(closeBudgetUI());+ void store.dispatch(closeBudgetUI());store.dispatch(setAppState({ loadingText: null }));});const unlistenApiFetchRedirected = listen('api-fetch-redirected', () => {- window.Actual.reload();+ void window.Actual.reload();});return () => {diff --git a/packages/desktop-client/src/hooks/useBudgetAutomations.ts b/packages/desktop-client/src/hooks/useBudgetAutomations.tsindex 5a6cac6a3b..3ef99a5e9a 100644--- a/packages/desktop-client/src/hooks/useBudgetAutomations.ts+++ b/packages/desktop-client/src/hooks/useBudgetAutomations.ts@@ -30,7 +30,7 @@ export function useBudgetAutomations({setLoading(false);}}- fetchAutomations();+ void fetchAutomations();return () => {mounted = false;};diff --git a/packages/desktop-client/src/hooks/useFormulaExecution.ts b/packages/desktop-client/src/hooks/useFormulaExecution.tsindex 564d9b4eef..da8186cf4d 100644--- a/packages/desktop-client/src/hooks/useFormulaExecution.ts+++ b/packages/desktop-client/src/hooks/useFormulaExecution.ts@@ -180,7 +180,7 @@ export function useFormulaExecution(}}- executeFormula();+ void executeFormula();return () => {cancelled = true;diff --git a/packages/desktop-client/src/hooks/useGlobalPref.ts b/packages/desktop-client/src/hooks/useGlobalPref.tsindex c577cef706..e2ea61c013 100644--- a/packages/desktop-client/src/hooks/useGlobalPref.ts+++ b/packages/desktop-client/src/hooks/useGlobalPref.ts@@ -16,7 +16,7 @@ export function useGlobalPref<K extends keyof GlobalPrefs>(const dispatch = useDispatch();const setGlobalPref = useCallback<SetGlobalPrefAction<K>>(value => {- dispatch(+ void dispatch(saveGlobalPrefs({prefs: {[prefName]: value,diff --git a/packages/desktop-client/src/hooks/useGoCardlessStatus.ts b/packages/desktop-client/src/hooks/useGoCardlessStatus.tsindex 3e06477fda..fce56187fb 100644--- a/packages/desktop-client/src/hooks/useGoCardlessStatus.ts+++ b/packages/desktop-client/src/hooks/useGoCardlessStatus.ts@@ -22,7 +22,7 @@ export function useGoCardlessStatus() {}if (status === 'online') {- fetch();+ void fetch();}}, [status]);diff --git a/packages/desktop-client/src/hooks/useMetadataPref.ts b/packages/desktop-client/src/hooks/useMetadataPref.tsindex 3bd6f0ac36..a5253fb0ad 100644--- a/packages/desktop-client/src/hooks/useMetadataPref.ts+++ b/packages/desktop-client/src/hooks/useMetadataPref.ts@@ -15,7 +15,7 @@ export function useMetadataPref<K extends keyof MetadataPrefs>(const dispatch = useDispatch();const setLocalPref = useCallback<SetMetadataPrefAction<K>>(value => {- dispatch(savePrefs({ prefs: { [prefName]: value } }));+ void dispatch(savePrefs({ prefs: { [prefName]: value } }));},[prefName, dispatch],);diff --git a/packages/desktop-client/src/hooks/useNavigate.ts b/packages/desktop-client/src/hooks/useNavigate.tsindex 9cabcc1cfa..b8d97f37fa 100644--- a/packages/desktop-client/src/hooks/useNavigate.ts+++ b/packages/desktop-client/src/hooks/useNavigate.ts@@ -17,7 +17,7 @@ export function useNavigate(): NavigateFunction {return useCallback((to: To | number, options: NavigateOptions = {}) => {if (typeof to === 'number') {- navigate(to);+ void navigate(to);} else {const optionsWithPrevLocation: NavigateOptions = {replace:@@ -38,10 +38,10 @@ export function useNavigate(): NavigateFunction {JSON.stringify(options?.state || {}) !==JSON.stringify(previousOriginalState)) {- navigate(to, optionsWithPrevLocation);+ void navigate(to, optionsWithPrevLocation);} else {// `to` is the same as the previous location. Just go back.- navigate(-1);+ void navigate(-1);}}},diff --git a/packages/desktop-client/src/hooks/usePluggyAiStatus.ts b/packages/desktop-client/src/hooks/usePluggyAiStatus.tsindex dfe6583a25..9ab5a49fa4 100644--- a/packages/desktop-client/src/hooks/usePluggyAiStatus.ts+++ b/packages/desktop-client/src/hooks/usePluggyAiStatus.ts@@ -22,7 +22,7 @@ export function usePluggyAiStatus() {}if (status === 'online') {- fetch();+ void fetch();}}, [status]);diff --git a/packages/desktop-client/src/hooks/useScheduleEdit.ts b/packages/desktop-client/src/hooks/useScheduleEdit.tsindex 529027b868..7150f294e1 100644--- a/packages/desktop-client/src/hooks/useScheduleEdit.ts+++ b/packages/desktop-client/src/hooks/useScheduleEdit.ts@@ -289,7 +289,7 @@ export function useScheduleEdit({// Load schedule on mountuseEffect(() => {- setSchedule();+ void setSchedule();}, []);// Update upcoming dates when date changes@@ -318,7 +318,7 @@ export function useScheduleEdit({});dispatch({ type: 'set-upcoming-dates', dates: data });}- run();+ void run();}, [state.fields.date]);// Load linked transactions@@ -372,7 +372,7 @@ export function useScheduleEdit({return typedCond;});- send('make-filters-from-conditions', {+ void send('make-filters-from-conditions', {conditions,}).then(({ filters }) => {if (current) {diff --git a/packages/desktop-client/src/hooks/useSendPlatformRequest.ts b/packages/desktop-client/src/hooks/useSendPlatformRequest.tsindex 4434157281..df610b5194 100644--- a/packages/desktop-client/src/hooks/useSendPlatformRequest.ts+++ b/packages/desktop-client/src/hooks/useSendPlatformRequest.ts@@ -19,7 +19,7 @@ export function useSendPlatformRequest<K extends keyof Handlers>(setIsLoading(false);}- run();+ void run();}, [name, args, options]);return {diff --git a/packages/desktop-client/src/hooks/useServerPref.ts b/packages/desktop-client/src/hooks/useServerPref.tsindex e89590a676..2002d54e8e 100644--- a/packages/desktop-client/src/hooks/useServerPref.ts+++ b/packages/desktop-client/src/hooks/useServerPref.ts@@ -16,7 +16,7 @@ export function useServerPref<K extends keyof ServerPrefs>(const setPref = useCallback<SetServerPrefAction<K>>(value => {- dispatch(+ void dispatch(saveServerPrefs({prefs: { [prefName]: value },}),diff --git a/packages/desktop-client/src/hooks/useSimpleFinStatus.ts b/packages/desktop-client/src/hooks/useSimpleFinStatus.tsindex f6310cb389..a4eb8879d5 100644--- a/packages/desktop-client/src/hooks/useSimpleFinStatus.ts+++ b/packages/desktop-client/src/hooks/useSimpleFinStatus.ts@@ -22,7 +22,7 @@ export function useSimpleFinStatus() {}if (status === 'online') {- fetch();+ void fetch();}}, [status]);diff --git a/packages/desktop-client/src/hooks/useSpreadsheet.tsx b/packages/desktop-client/src/hooks/useSpreadsheet.tsxindex 87f347e56f..9b16bdc80d 100644--- a/packages/desktop-client/src/hooks/useSpreadsheet.tsx+++ b/packages/desktop-client/src/hooks/useSpreadsheet.tsx@@ -87,7 +87,7 @@ function makeSpreadsheet() {binding = typeof binding === 'string' ? { name: binding } : binding;if (binding.query) {- this.createQuery(sheetName, binding.name, binding.query);+ void this.createQuery(sheetName, binding.name, binding.query);}const resolvedName = `${sheetName}!${binding.name}`;@@ -104,12 +104,12 @@ function makeSpreadsheet() {}if (cellCache[resolvedName] != null) {- cellCache[resolvedName].then(callback);+ void cellCache[resolvedName].then(callback);} else {const req = this.get(sheetName, binding.name);cellCache[resolvedName] = req;- req.then(result => {+ void req.then(result => {// We only want to call the callback if it's still waiting on// the same request. If we've received a `cells-changed` event// for this already then it's already been called and we don'tdiff --git a/packages/desktop-client/src/hooks/useSyncedPref.ts b/packages/desktop-client/src/hooks/useSyncedPref.tsindex 401c0be30a..2d18e458ce 100644--- a/packages/desktop-client/src/hooks/useSyncedPref.ts+++ b/packages/desktop-client/src/hooks/useSyncedPref.ts@@ -15,7 +15,7 @@ export function useSyncedPref<K extends keyof SyncedPrefs>(const dispatch = useDispatch();const setPref = useCallback<SetSyncedPrefAction<K>>(value => {- dispatch(+ void dispatch(saveSyncedPrefs({prefs: { [prefName]: value },}),diff --git a/packages/desktop-client/src/hooks/useSyncedPrefs.ts b/packages/desktop-client/src/hooks/useSyncedPrefs.tsindex d7c5a48fcb..8f8bf2c72e 100644--- a/packages/desktop-client/src/hooks/useSyncedPrefs.ts+++ b/packages/desktop-client/src/hooks/useSyncedPrefs.ts@@ -12,7 +12,7 @@ export function useSyncedPrefs(): [SyncedPrefs, SetSyncedPrefsAction] {const dispatch = useDispatch();const setPrefs = useCallback<SetSyncedPrefsAction>(newValue => {- dispatch(saveSyncedPrefs({ prefs: newValue }));+ void dispatch(saveSyncedPrefs({ prefs: newValue }));},[dispatch],);diff --git a/packages/desktop-client/src/hooks/useThemeCatalog.ts b/packages/desktop-client/src/hooks/useThemeCatalog.tsindex 0c123b3b4d..31946ea3ff 100644--- a/packages/desktop-client/src/hooks/useThemeCatalog.ts+++ b/packages/desktop-client/src/hooks/useThemeCatalog.ts@@ -41,7 +41,7 @@ export function useThemeCatalog() {}};- fetchCatalog();+ void fetchCatalog();}, []);return {diff --git a/packages/desktop-client/src/hooks/useTransactionBatchActions.ts b/packages/desktop-client/src/hooks/useTransactionBatchActions.tsindex 1ba930924c..d13f9295ef 100644--- a/packages/desktop-client/src/hooks/useTransactionBatchActions.ts+++ b/packages/desktop-client/src/hooks/useTransactionBatchActions.ts@@ -276,7 +276,7 @@ export function useTransactionBatchActions() {if (name === 'cleared') {// Cleared just toggles it on/off and it depends on the data// loaded. Need to clean this up in the future.- onChange('cleared', null);+ void onChange('cleared', null);} else if (name === 'category') {pushCategoryAutocompleteModal();} else if (name === 'payee') {diff --git a/packages/desktop-client/src/hooks/useTransactionFormulaExecution.ts b/packages/desktop-client/src/hooks/useTransactionFormulaExecution.tsindex 2f166eab23..52ef8e12ff 100644--- a/packages/desktop-client/src/hooks/useTransactionFormulaExecution.ts+++ b/packages/desktop-client/src/hooks/useTransactionFormulaExecution.ts@@ -113,7 +113,7 @@ export function useTransactionFormulaExecution(}}- executeFormula();+ void executeFormula();return () => {cancelled = true;diff --git a/packages/desktop-client/src/hooks/useTransactions.ts b/packages/desktop-client/src/hooks/useTransactions.tsindex 4312153685..5ea7fd10bd 100644--- a/packages/desktop-client/src/hooks/useTransactions.ts+++ b/packages/desktop-client/src/hooks/useTransactions.ts@@ -116,7 +116,7 @@ export function useTransactions({tables.includes('category_mapping') ||tables.includes('payee_mapping')) {- queryResult.refetch();+ void queryResult.refetch();}}});diff --git a/packages/desktop-client/src/i18n.ts b/packages/desktop-client/src/i18n.tsindex cc4a5fc187..65713473f8 100644--- a/packages/desktop-client/src/i18n.ts+++ b/packages/desktop-client/src/i18n.ts@@ -21,7 +21,7 @@ const loadLanguage = (language: string) => {return languages[`/locale/${language}.json`]();};-i18n+void i18n.use(initReactI18next).use(resourcesToBackend(loadLanguage)).init({@@ -90,5 +90,5 @@ export const setI18NextLanguage = (language: string | null) => {return; // language is already set}- i18n.changeLanguage(resolved);+ void i18n.changeLanguage(resolved);};diff --git a/packages/desktop-client/src/index.tsx b/packages/desktop-client/src/index.tsxindex 6b1eb035c8..c88d1a79fd 100644--- a/packages/desktop-client/src/index.tsx+++ b/packages/desktop-client/src/index.tsx@@ -53,7 +53,7 @@ async function appFocused() {}async function uploadFile(filename: string, contents: ArrayBuffer) {- send('upload-file-web', {+ await send('upload-file-web', {filename,contents,});diff --git a/packages/desktop-client/src/queries/liveQuery.test.ts b/packages/desktop-client/src/queries/liveQuery.test.tsindex 207beeb956..7a299b0637 100644--- a/packages/desktop-client/src/queries/liveQuery.test.ts+++ b/packages/desktop-client/src/queries/liveQuery.test.ts@@ -182,15 +182,15 @@ describe('liveQuery', () => {// Users should never call `run` manually but we'll do it to// test- lq.run();+ void lq.run();await wait(0);- lq.run();+ void lq.run();await wait(0);- lq.run();+ void lq.run();await wait(0);- lq.run();+ void lq.run();await wait(0);- lq.run();+ void lq.run();// Wait for the same delay the server hasawait wait(500);diff --git a/packages/desktop-client/src/queries/liveQuery.ts b/packages/desktop-client/src/queries/liveQuery.tsindex 27030be177..79e6602ff1 100644--- a/packages/desktop-client/src/queries/liveQuery.ts+++ b/packages/desktop-client/src/queries/liveQuery.ts@@ -114,7 +114,7 @@ export class LiveQuery<TResponse = unknown> {this._dependencies == null ||tables.find(table => this._dependencies.has(table))) {- this.run();+ void this.run();}};@@ -130,7 +130,7 @@ export class LiveQuery<TResponse = unknown> {options: LiveQueryOptions = {},) => {const liveQuery = new LiveQuery<TResponse>(query, onData, onError, options);- liveQuery.run();+ void liveQuery.run();return liveQuery;};diff --git a/packages/desktop-client/src/queries/pagedQuery.test.ts b/packages/desktop-client/src/queries/pagedQuery.test.tsindex 4ac57a1c2a..2b6510a698 100644--- a/packages/desktop-client/src/queries/pagedQuery.test.ts+++ b/packages/desktop-client/src/queries/pagedQuery.test.ts@@ -275,15 +275,15 @@ describe('pagedQuery', () => {// Users should never call `run` manually but we'll do it to// test- lq.run();+ void lq.run();await wait(0);- lq.run();+ void lq.run();await wait(0);- lq.run();+ void lq.run();await wait(0);- lq.run();+ void lq.run();await wait(0);- lq.run();+ void lq.run();// Wait for the same delay the server hasawait wait(500);@@ -469,10 +469,10 @@ describe('pagedQuery', () => {await tracer.expect('server-query', ['id']);await tracer.expect('data', vi.fn());- paged.fetchNext();- paged.fetchNext();+ void paged.fetchNext();+ void paged.fetchNext();await wait(2);- paged.fetchNext();+ void paged.fetchNext();await tracer.expect('server-query', ['id']);await tracer.expect('data', vi.fn());@@ -538,7 +538,7 @@ describe('pagedQuery', () => {tracer.start();- paged.fetchNext().then(() => {+ void paged.fetchNext().then(() => {tracer.event('page-finished');});@@ -586,7 +586,7 @@ describe('pagedQuery', () => {tracer.start();const item = data.find(row => row.id === 300);- paged.refetchUpToRow(item.id, { field: 'date', order: 'desc' });+ void paged.refetchUpToRow(item.id, { field: 'date', order: 'desc' });await tracer.expect('server-query',diff --git a/packages/desktop-client/src/queries/pagedQuery.ts b/packages/desktop-client/src/queries/pagedQuery.tsindex 4d297d6e99..4db0bdcb7f 100644--- a/packages/desktop-client/src/queries/pagedQuery.ts+++ b/packages/desktop-client/src/queries/pagedQuery.ts@@ -85,7 +85,7 @@ export class PagedQuery<TResponse = unknown> extends LiveQuery<TResponse> {this._hasReachedEnd = false;// Also fetch the total count- this.fetchCount();+ void this.fetchCount();// If data is null, we haven't fetched anything yet so just// fetch the first page@@ -115,7 +115,7 @@ export class PagedQuery<TResponse = unknown> extends LiveQuery<TResponse> {onPageData,options,);- pagedQuery.run();+ void pagedQuery.run();return pagedQuery;};@@ -124,7 +124,7 @@ export class PagedQuery<TResponse = unknown> extends LiveQuery<TResponse> {this._hasReachedEnd = false;// Also fetch the total count- this.fetchCount();+ void this.fetchCount();const orderDesc = getPrimaryOrderBy(this.query, defaultOrderBy);if (orderDesc == null) {diff --git a/packages/desktop-client/src/reports/mutations.ts b/packages/desktop-client/src/reports/mutations.tsindex f7ee5651d2..f8126f192a 100644--- a/packages/desktop-client/src/reports/mutations.ts+++ b/packages/desktop-client/src/reports/mutations.ts@@ -34,7 +34,7 @@ function invalidateReportQueries(queryClient: QueryClient,queryKey?: QueryKey,) {- queryClient.invalidateQueries({+ void queryClient.invalidateQueries({queryKey: queryKey ?? reportQueries.lists(),});}@@ -43,7 +43,7 @@ function invalidateDashboardQueries(queryClient: QueryClient,queryKey?: QueryKey,) {- queryClient.invalidateQueries({+ void queryClient.invalidateQueries({queryKey: queryKey ?? dashboardQueries.lists(),});}diff --git a/packages/desktop-client/src/setupTests.ts b/packages/desktop-client/src/setupTests.tsindex 37cacec626..56b6507cac 100644--- a/packages/desktop-client/src/setupTests.ts+++ b/packages/desktop-client/src/setupTests.ts@@ -4,7 +4,7 @@ import type { ReactNode } from 'react';import { resetTestProviders } from './mocks';import { installPolyfills } from './polyfills';-installPolyfills();+void installPolyfills();global.IS_TESTING = true;global.Actual = {} as typeof global.Actual;diff --git a/packages/desktop-client/src/sync-events.ts b/packages/desktop-client/src/sync-events.tsindex 392a6c8e1e..489c9b2db1 100644--- a/packages/desktop-client/src/sync-events.ts+++ b/packages/desktop-client/src/sync-events.ts@@ -62,7 +62,7 @@ export function listenForSyncEvent(store: AppStore, queryClient: QueryClient) {const tables = event.tables;if (tables.includes('prefs')) {- store.dispatch(loadPrefs());+ void store.dispatch(loadPrefs());}if (@@ -70,7 +70,7 @@ export function listenForSyncEvent(store: AppStore, queryClient: QueryClient) {tables.includes('category_groups') ||tables.includes('category_mapping')) {- queryClient.invalidateQueries({+ void queryClient.invalidateQueries({queryKey: categoryQueries.lists(),});}@@ -81,13 +81,13 @@ export function listenForSyncEvent(store: AppStore, queryClient: QueryClient) {tables.includes('payees') ||tables.includes('payee_mapping')) {- queryClient.invalidateQueries({+ void queryClient.invalidateQueries({queryKey: payeeQueries.lists(),});}if (tables.includes('accounts')) {- queryClient.invalidateQueries({+ void queryClient.invalidateQueries({queryKey: accountQueries.lists(),});}@@ -113,7 +113,7 @@ export function listenForSyncEvent(store: AppStore, queryClient: QueryClient) {button: {title: t('Reset sync'),action: () => {- store.dispatch(resetSync());+ void store.dispatch(resetSync());},},};@@ -136,7 +136,7 @@ export function listenForSyncEvent(store: AppStore, queryClient: QueryClient) {action: async () => {attemptedSyncRepair = true;await send('sync-repair');- store.dispatch(sync());+ void store.dispatch(sync());},},};@@ -169,7 +169,7 @@ export function listenForSyncEvent(store: AppStore, queryClient: QueryClient) {button: {title: t('Reset sync'),action: () => {- store.dispatch(resetSync());+ void store.dispatch(resetSync());},},};@@ -219,8 +219,8 @@ export function listenForSyncEvent(store: AppStore, queryClient: QueryClient) {title: t('Register'),action: async () => {await store.dispatch(uploadBudget({}));- store.dispatch(sync());- store.dispatch(loadPrefs());+ void store.dispatch(sync());+ void store.dispatch(loadPrefs());},},};@@ -241,7 +241,7 @@ export function listenForSyncEvent(store: AppStore, queryClient: QueryClient) {button: {title: t('Upload'),action: () => {- store.dispatch(resetSync());+ void store.dispatch(resetSync());},},};@@ -277,7 +277,7 @@ export function listenForSyncEvent(store: AppStore, queryClient: QueryClient) {button: {title: t('Revert'),action: () => {- store.dispatch(closeAndDownloadBudget({ cloudFileId }));+ void store.dispatch(closeAndDownloadBudget({ cloudFileId }));},},};@@ -366,7 +366,7 @@ export function listenForSyncEvent(store: AppStore, queryClient: QueryClient) {break;case 'token-expired':notif = null;- store.dispatch(signOut());+ void store.dispatch(signOut());break;default:console.trace('unknown error', event);diff --git a/packages/desktop-client/src/tags/mutations.ts b/packages/desktop-client/src/tags/mutations.tsindex db55fa2070..bc44aac9aa 100644--- a/packages/desktop-client/src/tags/mutations.ts+++ b/packages/desktop-client/src/tags/mutations.ts@@ -14,7 +14,7 @@ import { useDispatch } from '@desktop-client/redux';import type { AppDispatch } from '@desktop-client/redux/store';function invalidateQueries(queryClient: QueryClient, queryKey?: QueryKey) {- queryClient.invalidateQueries({+ void queryClient.invalidateQueries({queryKey: queryKey ?? tagQueries.lists(),});}diff --git a/packages/desktop-client/src/users/usersSlice.ts b/packages/desktop-client/src/users/usersSlice.tsindex db7ad9a2fa..518d87bbb3 100644--- a/packages/desktop-client/src/users/usersSlice.ts+++ b/packages/desktop-client/src/users/usersSlice.ts@@ -42,7 +42,7 @@ export const loggedIn = createAppAsyncThunk(// their account is invalid. So we should list all their files// regardless. Previously, we kicked users out to a "need payment// info" screen and we didn't want to call this.- dispatch(loadAllFiles());+ void dispatch(loadAllFiles());},);@@ -51,9 +51,9 @@ export const signOut = createAppAsyncThunk(async (_, { dispatch }) => {await send('subscribe-sign-out');- dispatch(getUserData());- dispatch(loadGlobalPrefs());- dispatch(closeBudget());+ void dispatch(getUserData());+ void dispatch(loadGlobalPrefs());+ void dispatch(closeBudget());// Handled in budgetSlice// dispatch({ type: constants.SIGN_OUT });},diff --git a/packages/desktop-electron/index.ts b/packages/desktop-electron/index.tsindex 68689b4e55..db119b286a 100644--- a/packages/desktop-electron/index.ts+++ b/packages/desktop-electron/index.ts@@ -85,7 +85,7 @@ const logMessage = (loglevel: 'info' | 'error', message: string) => {queuedClientWinLogs.push(`console.${loglevel}(${trimmedMessage})`);} else {// Send the queued up logs to the devtools console- clientWin.webContents.executeJavaScript(+ void clientWin.webContents.executeJavaScript(`console.${loglevel}(${trimmedMessage})`,);}@@ -107,9 +107,11 @@ const createOAuthServer = async () => {const code = query.get('token');if (code && clientWin) {if (isDev) {- clientWin.loadURL(`http://localhost:3001/openid-cb?token=${code}`);+ void clientWin.loadURL(+ `http://localhost:3001/openid-cb?token=${code}`,+ );} else {- clientWin.loadURL(`app://actual/openid-cb?token=${code}`);+ void clientWin.loadURL(`app://actual/openid-cb?token=${code}`);}// Respond to the browser@@ -264,7 +266,7 @@ async function startSyncServer() {// ACTUAL_SERVER_DATA_DIR is the root directory for the sync-serverif (!fs.existsSync(syncServerConfig.ACTUAL_SERVER_DATA_DIR)) {- mkdir(syncServerConfig.ACTUAL_SERVER_DATA_DIR, { recursive: true });+ void mkdir(syncServerConfig.ACTUAL_SERVER_DATA_DIR, { recursive: true });}let forkOptions: ForkOptions = {@@ -360,13 +362,15 @@ async function createWindow() {const unlistenToState = listenToWindowState(win, windowState);if (isDev) {- win.loadURL(`file://${__dirname}/loading.html`);+ void win.loadURL(`file://${__dirname}/loading.html`);// Wait for the development server to startsetTimeout(() => {- promiseRetry(retry => win.loadURL('http://localhost:3001/').catch(retry));+ void promiseRetry(retry =>+ win.loadURL('http://localhost:3001/').catch(retry),+ );}, 3000);} else {- win.loadURL(`app://actual/`);+ void win.loadURL(`app://actual/`);}win.on('closed', () => {@@ -385,7 +389,7 @@ async function createWindow() {if (clientWin) {const url = clientWin.webContents.getURL();if (url.includes('app://') || url.includes('localhost:')) {- clientWin.webContents.executeJavaScript(+ void clientWin.webContents.executeJavaScript('window.__actionsForMenu.appFocused()',);}@@ -396,7 +400,7 @@ async function createWindow() {// always deny, optionally redirect to browserwin.webContents.setWindowOpenHandler(({ url }) => {if (isExternalUrl(url)) {- shell.openExternal(url);+ void shell.openExternal(url);}return { action: 'deny' };@@ -406,7 +410,7 @@ async function createWindow() {// optionally redirect to browserwin.webContents.on('will-navigate', (event, url) => {if (isExternalUrl(url)) {- shell.openExternal(url);+ void shell.openExternal(url);event.preventDefault();}});@@ -515,7 +519,7 @@ app.on('before-quit', () => {app.on('activate', () => {if (clientWin === null) {- createWindow();+ void createWindow();}});@@ -553,7 +557,7 @@ ipcMain.handle('restart-server', () => {serverProcess = null;}- createBackgroundProcess();+ void createBackgroundProcess();});ipcMain.handle('relaunch', () => {@@ -606,7 +610,7 @@ ipcMain.handle();ipcMain.handle('open-external-url', (event, url) => {- shell.openExternal(url);+ void shell.openExternal(url);});ipcMain.handle('open-in-file-manager', (event, filepath) => {@@ -624,7 +628,7 @@ ipcMain.on('message', (_event, msg) => {ipcMain.on('set-theme', (_event, theme: string) => {const obj = { theme };if (clientWin) {- clientWin.webContents.executeJavaScript(+ void clientWin.webContents.executeJavaScript(`window.__actionsForMenu && window.__actionsForMenu.saveGlobalPrefs({ prefs: ${JSON.stringify(obj)} })`,);}diff --git a/packages/desktop-electron/menu.ts b/packages/desktop-electron/menu.tsindex c6ac72458c..41ebb3c021 100644--- a/packages/desktop-electron/menu.ts+++ b/packages/desktop-electron/menu.ts@@ -71,7 +71,7 @@ export function getMenu() {click: function (_menuItem, focusedWin) {// Undoif (focusedWin) {- (focusedWin as BrowserWindow).webContents.executeJavaScript(+ void (focusedWin as BrowserWindow).webContents.executeJavaScript('__actionsForMenu.undo()',);}@@ -84,7 +84,7 @@ export function getMenu() {click: function (_menuItem, focusedWin) {// Redoif (focusedWin) {- (focusedWin as BrowserWindow).webContents.executeJavaScript(+ void (focusedWin as BrowserWindow).webContents.executeJavaScript('__actionsForMenu.redo()',);}diff --git a/packages/desktop-electron/preload.ts b/packages/desktop-electron/preload.tsindex f2278cf9cb..90341a8e6a 100644--- a/packages/desktop-electron/preload.ts+++ b/packages/desktop-electron/preload.ts@@ -39,11 +39,11 @@ contextBridge.exposeInMainWorld('Actual', {startOAuthServer: () => ipcRenderer.invoke('start-oauth-server'),relaunch: () => {- ipcRenderer.invoke('relaunch');+ void ipcRenderer.invoke('relaunch');},restartElectronServer: () => {- ipcRenderer.invoke('restart-server');+ void ipcRenderer.invoke('restart-server');},openFileDialog: (opts: OpenFileDialogPayload) => {@@ -63,11 +63,11 @@ contextBridge.exposeInMainWorld('Actual', {},openURLInBrowser: (url: string) => {- ipcRenderer.invoke('open-external-url', url);+ void ipcRenderer.invoke('open-external-url', url);},openInFileManager: (filepath: string) => {- ipcRenderer.invoke('open-in-file-manager', filepath);+ void ipcRenderer.invoke('open-in-file-manager', filepath);},onEventFromMain: (type: string, handler: (...args: unknown[]) => void) => {diff --git a/packages/desktop-electron/server.ts b/packages/desktop-electron/server.tsindex f48c946869..8f7fc61719 100644--- a/packages/desktop-electron/server.ts+++ b/packages/desktop-electron/server.ts@@ -43,4 +43,4 @@ const lazyLoadBackend = async (isDev: boolean) => {const isDev = false;// Start the app-lazyLoadBackend(isDev);+void lazyLoadBackend(isDev);diff --git a/packages/eslint-plugin-actual/lib/rules/__tests__/no-anchor-tag.test.js b/packages/eslint-plugin-actual/lib/rules/__tests__/no-anchor-tag.test.jsindex 128ac7907c..83e522816a 100644--- a/packages/eslint-plugin-actual/lib/rules/__tests__/no-anchor-tag.test.js+++ b/packages/eslint-plugin-actual/lib/rules/__tests__/no-anchor-tag.test.js@@ -10,7 +10,7 @@ import * as rule from '../no-anchor-tag';// Tests//-------------------------------------------------------------------------------runClassic(+void runClassic('no-anchor-tag',rule,{diff --git a/packages/eslint-plugin-actual/lib/rules/__tests__/no-react-default-import.test.js b/packages/eslint-plugin-actual/lib/rules/__tests__/no-react-default-import.test.jsindex 4158fe0bf0..cb14ea26f8 100644--- a/packages/eslint-plugin-actual/lib/rules/__tests__/no-react-default-import.test.js+++ b/packages/eslint-plugin-actual/lib/rules/__tests__/no-react-default-import.test.js@@ -10,7 +10,7 @@ import * as rule from '../no-react-default-import';// Tests//-------------------------------------------------------------------------------runClassic(+void runClassic('no-react-default-import',rule,{diff --git a/packages/eslint-plugin-actual/lib/rules/__tests__/object-shorthand-properties.test.js b/packages/eslint-plugin-actual/lib/rules/__tests__/object-shorthand-properties.test.jsindex 9f401c97ab..e8a98db3d5 100644--- a/packages/eslint-plugin-actual/lib/rules/__tests__/object-shorthand-properties.test.js+++ b/packages/eslint-plugin-actual/lib/rules/__tests__/object-shorthand-properties.test.js@@ -10,7 +10,7 @@ import * as rule from '../object-shorthand-properties';// Tests//-------------------------------------------------------------------------------runClassic(+void runClassic('object-shorthand-properties',rule,{diff --git a/packages/eslint-plugin-actual/lib/rules/__tests__/prefer-const.test.js b/packages/eslint-plugin-actual/lib/rules/__tests__/prefer-const.test.jsindex 35c75edae9..a4c3df9850 100644--- a/packages/eslint-plugin-actual/lib/rules/__tests__/prefer-const.test.js+++ b/packages/eslint-plugin-actual/lib/rules/__tests__/prefer-const.test.js@@ -10,7 +10,7 @@ import * as rule from '../prefer-const';// Tests//-------------------------------------------------------------------------------runClassic(+void runClassic('prefer-const',rule,{diff --git a/packages/eslint-plugin-actual/lib/rules/__tests__/prefer-if-statement.test.js b/packages/eslint-plugin-actual/lib/rules/__tests__/prefer-if-statement.test.jsindex fee9949770..2a2af4e81c 100644--- a/packages/eslint-plugin-actual/lib/rules/__tests__/prefer-if-statement.test.js+++ b/packages/eslint-plugin-actual/lib/rules/__tests__/prefer-if-statement.test.js@@ -10,7 +10,7 @@ import * as rule from '../prefer-if-statement';// Tests//-------------------------------------------------------------------------------runClassic(+void runClassic('prefer-if-statement',rule,{diff --git a/packages/eslint-plugin-actual/lib/rules/__tests__/prefer-logger-over-console.test.js b/packages/eslint-plugin-actual/lib/rules/__tests__/prefer-logger-over-console.test.jsindex 46c37cc72d..6ac3e5d6e2 100644--- a/packages/eslint-plugin-actual/lib/rules/__tests__/prefer-logger-over-console.test.js+++ b/packages/eslint-plugin-actual/lib/rules/__tests__/prefer-logger-over-console.test.js@@ -2,7 +2,7 @@ import { runClassic } from 'eslint-vitest-rule-tester';import * as rule from '../prefer-logger-over-console';-runClassic(+void runClassic('prefer-logger-over-console',rule,{diff --git a/packages/eslint-plugin-actual/lib/rules/__tests__/typography.test.js b/packages/eslint-plugin-actual/lib/rules/__tests__/typography.test.jsindex 6bdb223617..b8d6c3f8d6 100644--- a/packages/eslint-plugin-actual/lib/rules/__tests__/typography.test.js+++ b/packages/eslint-plugin-actual/lib/rules/__tests__/typography.test.js@@ -10,7 +10,7 @@ import * as rule from '../typography';// Tests//-------------------------------------------------------------------------------runClassic(+void runClassic('typography',rule,{diff --git a/packages/loot-core/migrations/1722717601000_reports_move_selected_categories.js b/packages/loot-core/migrations/1722717601000_reports_move_selected_categories.jsindex e3333cc1dc..d238d76934 100644--- a/packages/loot-core/migrations/1722717601000_reports_move_selected_categories.js+++ b/packages/loot-core/migrations/1722717601000_reports_move_selected_categories.js@@ -1,11 +1,11 @@export default async function runMigration(db) {- const categories = await db.runQuery(+ const categories = db.runQuery('SELECT id FROM categories WHERE tombstone = 0',[],true,);- const customReports = await db.runQuery(+ const customReports = db.runQuery('SELECT id, selected_categories, conditions FROM custom_reports WHERE tombstone = 0 AND selected_categories IS NOT NULL',[],true,@@ -34,7 +34,7 @@ export default async function runMigration(db) {}// Append a new condition with the selected category IDs- await db.runQuery('UPDATE custom_reports SET conditions = ? WHERE id = ?', [+ db.runQuery('UPDATE custom_reports SET conditions = ? WHERE id = ?', [JSON.stringify([...conditions,{@@ -49,7 +49,7 @@ export default async function runMigration(db) {}// Remove all the `selectedCategories` values - we don't need them anymore- await db.runQuery(+ db.runQuery('UPDATE custom_reports SET selected_categories = NULL WHERE tombstone = 0',);}diff --git a/packages/loot-core/migrations/1723665565000_prefs.js b/packages/loot-core/migrations/1723665565000_prefs.jsindex 46829c706c..2cfaec6e68 100644--- a/packages/loot-core/migrations/1723665565000_prefs.js+++ b/packages/loot-core/migrations/1723665565000_prefs.js@@ -47,7 +47,7 @@ export default async function runMigration(db, { fs, fileId }) {}// insert the synced prefs in the new table- await db.runQuery('INSERT INTO preferences (id, value) VALUES (?, ?)', [+ db.runQuery('INSERT INTO preferences (id, value) VALUES (?, ?)', [key,String(prefs[key]),]);diff --git a/packages/loot-core/src/mocks/budget.ts b/packages/loot-core/src/mocks/budget.tsindex 029b23f735..67d6be5da8 100644--- a/packages/loot-core/src/mocks/budget.ts+++ b/packages/loot-core/src/mocks/budget.ts@@ -499,7 +499,7 @@ async function createBudget(accounts, payees, groups) {) as number;if (spent < 0) {- setBudget(month, cat, -spent);+ void setBudget(month, cat, -spent);}}@@ -510,19 +510,19 @@ async function createBudget(accounts, payees, groups) {month >=monthUtils.monthFromDate(db.fromDateRepr(earliestPrimaryDate))) {- setBudget(month, category('Food'), 40000);- setBudget(month, category('Restaurants'), 30000);- setBudget(month, category('Entertainment'), 10000);- setBudget(month, category('Clothing'), 3000);- setBudget(month, category('General'), 50000);- setBudget(month, category('Gift'), 7500);- setBudget(month, category('Medical'), 10000);-- setBudget(month, category('Cell'), 7500);- setBudget(month, category('Internet'), 6000);- setBudget(month, category('Mortgage'), 120000);- setBudget(month, category('Water'), 9000);- setBudget(month, category('Power'), 10000);+ void setBudget(month, category('Food'), 40000);+ void setBudget(month, category('Restaurants'), 30000);+ void setBudget(month, category('Entertainment'), 10000);+ void setBudget(month, category('Clothing'), 3000);+ void setBudget(month, category('General'), 50000);+ void setBudget(month, category('Gift'), 7500);+ void setBudget(month, category('Medical'), 10000);++ void setBudget(month, category('Cell'), 7500);+ void setBudget(month, category('Internet'), 6000);+ void setBudget(month, category('Mortgage'), 120000);+ void setBudget(month, category('Water'), 9000);+ void setBudget(month, category('Power'), 10000);} else {setBudgetIfSpent(month, category('Food'));setBudgetIfSpent(month, category('Restaurants'));@@ -561,12 +561,12 @@ async function createBudget(accounts, payees, groups) {const available = toBudget - prevSaved;if (available - 403000 > 0) {- setBudget(month, category('Savings'), available - 403000);- budgetActions.setBuffer(month, 403000);+ void setBudget(month, category('Savings'), available - 403000);+ void budgetActions.setBuffer(month, 403000);prevSaved += available - 403000;} else if (available > 0) {- budgetActions.setBuffer(month, available);+ void budgetActions.setBuffer(month, available);}}}@@ -597,13 +597,13 @@ async function createBudget(accounts, payees, groups) {export async function createTestBudget(handlers: Handlers) {setSyncingMode('import');- await db.execQuery('PRAGMA journal_mode = OFF');+ db.execQuery('PRAGMA journal_mode = OFF');// Clear out the default categories. This is fine to do without// going through the sync system because we are in import mode and// these aren't tracked through messages anyway.- await db.runQuery('DELETE FROM categories;');- await db.runQuery('DELETE FROM category_groups');+ db.runQuery('DELETE FROM categories;');+ db.runQuery('DELETE FROM category_groups');const accounts: { name: string; offBudget?: boolean; id?: string }[] = [{ name: 'Bank of America' },diff --git a/packages/loot-core/src/mocks/setup.ts b/packages/loot-core/src/mocks/setup.tsindex d60efd4025..de1aedcdd5 100644--- a/packages/loot-core/src/mocks/setup.ts+++ b/packages/loot-core/src/mocks/setup.ts@@ -79,7 +79,7 @@ vi.mock('../server/migrate/migrations', async () => {global.getDatabaseDump = async function (tables) {if (!tables) {- const rows = await sqlite.runQuery<{ name }>(+ const rows = sqlite.runQuery<{ name }>(db.getDatabase(),"SELECT name FROM sqlite_master WHERE type='table'",[],@@ -108,7 +108,7 @@ global.getDatabaseDump = async function (tables) {return [table,- await sqlite.runQuery(+ sqlite.runQuery(db.getDatabase(),'SELECT * FROM ' + table + ' ORDER BY ' + sortColumn,[],@@ -143,7 +143,7 @@ global.emptyDatabase = function (avoidUpdate) {);db.setDatabase(memoryDB);- await db.runQuery('INSERT INTO db_version (version) VALUES (?)', ['0.0.1']);+ db.runQuery('INSERT INTO db_version (version) VALUES (?)', ['0.0.1']);if (!avoidUpdate) {await updateVersion();@@ -161,7 +161,7 @@ beforeEach(() => {afterEach(() => {global.resetRandomId();tracer.end();- fetchClient.clearServer();+ void fetchClient.clearServer();return new Promise(resolve => {if (sheet.get()) {diff --git a/packages/loot-core/src/platform/client/connection/__mocks__/index.ts b/packages/loot-core/src/platform/client/connection/__mocks__/index.tsindex d6518d10b1..8b04b6e008 100644--- a/packages/loot-core/src/platform/client/connection/__mocks__/index.ts+++ b/packages/loot-core/src/platform/client/connection/__mocks__/index.ts@@ -29,7 +29,7 @@ export const clearServer: T.ClearServer = async () => {};export const serverPush: T.ServerPush = (name, args) => {- Promise.resolve().then(() => {+ void Promise.resolve().then(() => {const listens = listeners.get(name);if (listens) {listens.forEach(listener => {diff --git a/packages/loot-core/src/platform/server/asyncStorage/index.ts b/packages/loot-core/src/platform/server/asyncStorage/index.tsindex 978b8eae88..c6bdbec9ea 100644--- a/packages/loot-core/src/platform/server/asyncStorage/index.ts+++ b/packages/loot-core/src/platform/server/asyncStorage/index.ts@@ -28,7 +28,7 @@ export const setItem: T.SetItem = async function (key, value) {const transaction = db.transaction(['asyncStorage'], 'readwrite');const objectStore = transaction.objectStore('asyncStorage');- new Promise((resolve, reject) => {+ void new Promise((resolve, reject) => {const req = objectStore.put(value, key);req.onerror = e => reject(e);req.onsuccess = () => resolve(undefined);diff --git a/packages/loot-core/src/platform/server/fs/index.electron.ts b/packages/loot-core/src/platform/server/fs/index.electron.tsindex 4d4486cadf..67fdaaa6b7 100644--- a/packages/loot-core/src/platform/server/fs/index.electron.ts+++ b/packages/loot-core/src/platform/server/fs/index.electron.ts@@ -23,7 +23,7 @@ switch (path.basename(__filename)) {break;}-export const init = () => {+export const init = async () => {// Nothing to do};diff --git a/packages/loot-core/src/platform/server/fs/index.ts b/packages/loot-core/src/platform/server/fs/index.tsindex b613ffba38..60407ef88d 100644--- a/packages/loot-core/src/platform/server/fs/index.ts+++ b/packages/loot-core/src/platform/server/fs/index.ts@@ -1,6 +1,6 @@export { join } from './path-join';-export declare function init(): void;+export declare function init(): Promise<void>;export type Init = typeof init;export declare function getDataDir(): string;diff --git a/packages/loot-core/src/platform/server/fs/index.web.test.ts b/packages/loot-core/src/platform/server/fs/index.web.test.tsindex 2df8f65fc9..d901e2c401 100644--- a/packages/loot-core/src/platform/server/fs/index.web.test.ts+++ b/packages/loot-core/src/platform/server/fs/index.web.test.ts@@ -43,7 +43,7 @@ describe('web filesystem', () => {expect(await readFile('/documents/foo.bin')).toBe('hello, world');const db = await idb.openDatabase();- const { store } = await idb.getStore(db, 'files');+ const { store } = idb.getStore(db, 'files');// Make sure they are in idbexpect(await idb.get(store, '/documents/foo.txt')).toEqual({@@ -79,13 +79,16 @@ describe('web filesystem', () => {test('files are restored from idb', async () => {const db = await idb.openDatabase();- const { store } = await idb.getStore(db, 'files');- idb.set(store, { filepath: '/documents/ok.txt', contents: 'oh yeah' });- idb.set(store, {+ const { store } = idb.getStore(db, 'files');+ await idb.set(store, {+ filepath: '/documents/ok.txt',+ contents: 'oh yeah',+ });+ await idb.set(store, {filepath: '/documents/deep/nested/file/ok.txt',contents: 'deeper',});- idb.set(store, {+ await idb.set(store, {filepath: '/documents/deep/nested/db.sqlite',contents: 'this will be blank and just create a symlink',});diff --git a/packages/loot-core/src/platform/server/fs/index.web.ts b/packages/loot-core/src/platform/server/fs/index.web.tsindex d825471b0a..85132058d3 100644--- a/packages/loot-core/src/platform/server/fs/index.web.ts+++ b/packages/loot-core/src/platform/server/fs/index.web.ts@@ -166,7 +166,7 @@ async function _copySqlFile(): Promise<boolean> {_createFile(topath);- const { store } = await idb.getStore(await idb.getDatabase(), 'files');+ const { store } = idb.getStore(await idb.getDatabase(), 'files');await idb.set(store, { filepath: topath, contents: '' });const fromitem = await idb.get(store, frompath);const fromDbPath = pathToId(fromitem.filepath);@@ -192,7 +192,7 @@ async function _copySqlFile(} catch (error) {tofile.close();fromfile.close();- _removeFile(toDbPath);+ await _removeFile(toDbPath);logger.error('Failed to copy database file', error);return false;} finally {@@ -248,7 +248,7 @@ async function populateDefaultFilesystem() {await Promise.all(files.map(async file => {const contents = await fetchFile(process.env.PUBLIC_URL + 'data/' + file);- _writeFile('/' + file, contents);+ await _writeFile('/' + file, contents);}),);}diff --git a/packages/loot-core/src/platform/server/indexeddb/index.ts b/packages/loot-core/src/platform/server/indexeddb/index.tsindex aa2cd6d513..7ce5508979 100644--- a/packages/loot-core/src/platform/server/indexeddb/index.ts+++ b/packages/loot-core/src/platform/server/indexeddb/index.ts@@ -45,7 +45,7 @@ function _openDatabase() {db.onerror = function (event) {const error = (event.target as IDBOpenDBRequest)?.error;- logger.log('Database error: ' + error);+ logger.log('Database error:', error);if (event.target && error) {if (error.name === 'QuotaExceededError') {@@ -105,9 +105,9 @@ export const openDatabase = function () {return openedDb;};-export const closeDatabase = function () {+export const closeDatabase = async function () {if (openedDb) {- openedDb.then(db => {+ await openedDb.then(db => {db.close();});openedDb = null;diff --git a/packages/loot-core/src/platform/server/sqlite/index.electron.ts b/packages/loot-core/src/platform/server/sqlite/index.electron.tsindex c5d22a9017..53d95121bc 100644--- a/packages/loot-core/src/platform/server/sqlite/index.electron.ts+++ b/packages/loot-core/src/platform/server/sqlite/index.electron.ts@@ -117,7 +117,7 @@ export function openDatabase(pathOrBuffer: string | Buffer) {}export function closeDatabase(db: SQL.Database) {- return db.close();+ db.close();}export async function exportDatabase(db: SQL.Database) {diff --git a/packages/loot-core/src/platform/server/sqlite/index.ts b/packages/loot-core/src/platform/server/sqlite/index.tsindex c8881b35b7..50a1ef6944 100644--- a/packages/loot-core/src/platform/server/sqlite/index.ts+++ b/packages/loot-core/src/platform/server/sqlite/index.ts@@ -51,7 +51,9 @@ export declare function asyncTransaction(fn: () => Promise<void>,): Promise<void>;-export declare function openDatabase(pathOrBuffer?: string | Buffer): Database;+export declare function openDatabase(+ pathOrBuffer?: string | Buffer,+): Promise<Database>;export declare function closeDatabase(db: Database): void;diff --git a/packages/loot-core/src/server/accounts/app.ts b/packages/loot-core/src/server/accounts/app.tsindex 13462677f0..0b4587e92a 100644--- a/packages/loot-core/src/server/accounts/app.ts+++ b/packages/loot-core/src/server/accounts/app.ts@@ -277,7 +277,7 @@ async function linkSimpleFinAccount({startingBalance,);- await connection.send('sync-event', {+ connection.send('sync-event', {type: 'success',tables: ['transactions'],});@@ -349,7 +349,7 @@ async function linkPluggyAiAccount({startingBalance,);- await connection.send('sync-event', {+ connection.send('sync-event', {type: 'success',tables: ['transactions'],});@@ -430,7 +430,7 @@ async function closeAccount({if (numTransactions === 0) {await db.deleteAccount({ id });} else if (forced) {- const rows = await db.runQuery<+ const rows = db.runQuery<Pick<db.DbViewTransaction, 'id' | 'transfer_id'>>('SELECT id, transfer_id FROM v_transactions WHERE account = ?',@@ -456,18 +456,18 @@ async function closeAccount({rows.forEach(row => {if (row.transfer_id) {- db.updateTransaction({+ void db.updateTransaction({id: row.transfer_id,payee: null,transfer_id: null,});}- db.deleteTransaction({ id: row.id });+ void db.deleteTransaction({ id: row.id });});- db.deleteAccount({ id });- db.deleteTransferPayee({ id: transferPayee.id });+ void db.deleteAccount({ id });+ void db.deleteTransferPayee({ id: transferPayee.id });});} else {if (balance !== 0 && transferAccountId == null) {@@ -638,7 +638,7 @@ async function pollGoCardlessWebToken({}return new Promise(resolve => {- getData(data => {+ void getData(data => {if (data.status === 'success') {resolve({ data: data.data });return;@@ -951,9 +951,7 @@ async function accountsBankSync({const { 'user-id': userId, 'user-key': userKey } =await asyncStorage.multiGet(['user-id', 'user-key']);- const accounts = await db.runQuery<- db.DbAccount & { bankId: db.DbBank['bank_id'] }- >(+ const accounts = db.runQuery<db.DbAccount & { bankId: db.DbBank['bank_id'] }>(`SELECT a.*, b.bank_id as bankIdFROM accounts a@@ -1018,9 +1016,7 @@ async function simpleFinBatchSync({}): Promise<Array<{ accountId: AccountEntity['id']; res: SyncResponseWithErrors }>> {- const accounts = await db.runQuery<- db.DbAccount & { bankId: db.DbBank['bank_id'] }- >(+ const accounts = db.runQuery<db.DbAccount & { bankId: db.DbBank['bank_id'] }>(`SELECT a.*, b.bank_id as bankId FROM accounts aLEFT JOIN banks b ON a.bank = b.idWHEREdiff --git a/packages/loot-core/src/server/accounts/sync.ts b/packages/loot-core/src/server/accounts/sync.tsindex c957d187dc..7ec07dc847 100644--- a/packages/loot-core/src/server/accounts/sync.ts+++ b/packages/loot-core/src/server/accounts/sync.ts@@ -68,7 +68,7 @@ function getAccountBalance(account) {}async function updateAccountBalance(id: AccountEntity['id'], balance: number) {- await db.runQuery('UPDATE accounts SET balance_current = ? WHERE id = ?', [+ db.runQuery('UPDATE accounts SET balance_current = ? WHERE id = ?', [balance,id,]);diff --git a/packages/loot-core/src/server/api.ts b/packages/loot-core/src/server/api.tsindex 4b2cf60d3e..4881d7a2a7 100644--- a/packages/loot-core/src/server/api.ts+++ b/packages/loot-core/src/server/api.ts@@ -134,13 +134,13 @@ handlers['api/batch-budget-start'] = async function () {// transaction. Updating spreadsheet cells doesn't go through the// syncing layer in that case.if (IMPORT_MODE) {- db.asyncTransaction(() => {+ void db.asyncTransaction(() => {return new Promise((resolve, reject) => {batchPromise = { resolve, reject };});});} else {- batchMessages(() => {+ void batchMessages(() => {return new Promise((resolve, reject) => {batchPromise = { resolve, reject };});@@ -304,8 +304,8 @@ handlers['api/start-import'] = async function ({ budgetName }) {await handlers['create-budget']({ budgetName, avoidUpload: true });// Clear out the default expense categories- await db.runQuery('DELETE FROM categories WHERE is_income = 0');- await db.runQuery('DELETE FROM category_groups WHERE is_income = 0');+ db.runQuery('DELETE FROM categories WHERE is_income = 0');+ db.runQuery('DELETE FROM category_groups WHERE is_income = 0');// Turn syncing offsetSyncingMode('import');diff --git a/packages/loot-core/src/server/app.ts b/packages/loot-core/src/server/app.tsindex 694ef9da25..2896f0c6e4 100644--- a/packages/loot-core/src/server/app.ts+++ b/packages/loot-core/src/server/app.ts@@ -76,7 +76,7 @@ class App<Handlers> {this.unlistenServices = this.services.map(service => service());}- stopServices() {+ async stopServices() {this.unlistenServices.forEach(unlisten => {if (unlisten) {unlisten();diff --git a/packages/loot-core/src/server/aql/schema/executors.test.ts b/packages/loot-core/src/server/aql/schema/executors.test.tsindex e430dcca20..cd60cfd0db 100644--- a/packages/loot-core/src/server/aql/schema/executors.test.ts+++ b/packages/loot-core/src/server/aql/schema/executors.test.ts@@ -37,7 +37,7 @@ function aliveTransactions(arr) {async function insertTransactions(transactions, payeeIds?: string[]) {return batchMessages(async () => {for (const trans of transactions) {- db.insertTransaction(trans);+ void db.insertTransaction(trans);}if (payeeIds) {diff --git a/packages/loot-core/src/server/aql/schema/index.test.ts b/packages/loot-core/src/server/aql/schema/index.test.tsindex 1b519dc28b..d96a468c95 100644--- a/packages/loot-core/src/server/aql/schema/index.test.ts+++ b/packages/loot-core/src/server/aql/schema/index.test.ts@@ -16,7 +16,7 @@ describe('schema', () => {(await db.all<db.DbViewTransaction>('SELECT * FROM v_transactions')).length,).toBe(0);- await db.runQuery('INSERT INTO transactions (acct) VALUES (?)', ['foo']);+ db.runQuery('INSERT INTO transactions (acct) VALUES (?)', ['foo']);expect((await db.all<db.DbTransaction>('SELECT * FROM transactions')).length,).toBe(1);@@ -34,7 +34,7 @@ describe('schema', () => {(await db.all<db.DbViewTransaction>('SELECT * FROM v_transactions')).length,).toBe(0);- await db.runQuery('INSERT INTO transactions (date) VALUES (?)', [20200101]);+ db.runQuery('INSERT INTO transactions (date) VALUES (?)', [20200101]);expect((await db.all<db.DbTransaction>('SELECT * FROM transactions')).length,).toBe(1);@@ -52,7 +52,7 @@ describe('schema', () => {(await db.all<db.DbViewTransaction>('SELECT * FROM v_transactions')).length,).toBe(0);- await db.runQuery(+ db.runQuery('INSERT INTO transactions (date, acct, isChild) VALUES (?, ?, ?)',[20200101, 'foo', 1],);diff --git a/packages/loot-core/src/server/bench.ts b/packages/loot-core/src/server/bench.tsindex 92233ef111..2de0c1a10f 100644--- a/packages/loot-core/src/server/bench.ts+++ b/packages/loot-core/src/server/bench.ts@@ -26,4 +26,4 @@ async function run() {logger.log(Date.now() - start);}-run();+void run();diff --git a/packages/loot-core/src/server/budget/actions.ts b/packages/loot-core/src/server/budget/actions.tsindex 77a8bf9130..930460aaec 100644--- a/packages/loot-core/src/server/budget/actions.ts+++ b/packages/loot-core/src/server/budget/actions.ts@@ -16,7 +16,7 @@ export async function getSheetValue(sheetName: string,cell: string,): Promise<number> {- const node = await sheet.getCell(sheetName, cell);+ const node = sheet.getCell(sheetName, cell);return safeNumber(typeof node.value === 'number' ? node.value : 0);}@@ -24,7 +24,7 @@ export async function getSheetBoolean(sheetName: string,cell: string,): Promise<boolean> {- const node = await sheet.getCell(sheetName, cell);+ const node = sheet.getCell(sheetName, cell);return typeof node.value === 'boolean' ? node.value : false;}@@ -228,7 +228,7 @@ export async function copyPreviousMonth({if (prevBudget.hidden === 1 || prevBudget.group_hidden === 1) {return;}- setBudget({+ void setBudget({category: prevBudget.category,month,amount: prevBudget.amount,@@ -250,7 +250,7 @@ export async function copySinglePreviousMonth({'budget-' + category,);await batchMessages(async () => {- setBudget({ category, month, amount: newAmount });+ void setBudget({ category, month, amount: newAmount });});}@@ -264,7 +264,7 @@ export async function setZero({ month }: { month: string }): Promise<void> {if (cat.is_income === 1 && !isReflectBudget()) {return;}- setBudget({ category: cat.id, month, amount: 0 });+ void setBudget({ category: cat.id, month, amount: 0 });});});}@@ -312,7 +312,7 @@ export async function set3MonthAvg({avg *= -1;}- setBudget({ category: cat.id, month, amount: avg });+ void setBudget({ category: cat.id, month, amount: avg });}});}@@ -336,7 +336,7 @@ export async function set12MonthAvg({if (cat.is_income === 1 && !isReflectBudget()) {continue;}- setNMonthAvg({ month, N: 12, category: cat.id });+ void setNMonthAvg({ month, N: 12, category: cat.id });}});}@@ -360,7 +360,7 @@ export async function set6MonthAvg({if (cat.is_income === 1 && !isReflectBudget()) {continue;}- setNMonthAvg({ month, N: 6, category: cat.id });+ void setNMonthAvg({ month, N: 6, category: cat.id });}});}@@ -395,7 +395,7 @@ export async function setNMonthAvg({avg *= -1;}- setBudget({ category, month, amount: avg });+ void setBudget({ category, month, amount: avg });});}@@ -602,7 +602,7 @@ export async function setCategoryCarryover({await batchMessages(async () => {for (const month of months) {- setCarryover(table, category, dbMonth(month).toString(), flag);+ void setCarryover(table, category, dbMonth(month).toString(), flag);}});}diff --git a/packages/loot-core/src/server/budget/app.ts b/packages/loot-core/src/server/budget/app.tsindex ed6e4a5b37..807f8a8f61 100644--- a/packages/loot-core/src/server/budget/app.ts+++ b/packages/loot-core/src/server/budget/app.ts@@ -444,7 +444,7 @@ async function isCategoryTransferRequired({}: {id: CategoryEntity['id'];}) {- const res = await db.runQuery<{ count: number }>(+ const res = db.runQuery<{ count: number }>(`SELECT count(t.id) as count FROM transactions tLEFT JOIN category_mapping cm ON cm.id = t.categoryWHERE cm.transferId = ? AND t.tombstone = 0`,diff --git a/packages/loot-core/src/server/budget/base.ts b/packages/loot-core/src/server/budget/base.tsindex 2f892ac6a0..10308a6897 100644--- a/packages/loot-core/src/server/budget/base.ts+++ b/packages/loot-core/src/server/budget/base.ts@@ -60,7 +60,7 @@ export function createCategory(cat, sheetName, prevSheetName, start, end) {if (getBudgetType() === 'envelope') {envelopeBudget.createCategory(cat, sheetName, prevSheetName);} else {- report.createCategory(cat, sheetName, prevSheetName);+ void report.createCategory(cat, sheetName, prevSheetName);}}@@ -217,7 +217,7 @@ export async function doTransfer(categoryIds, transferId) {category: transferId,});- budgetActions.setBudget({+ void budgetActions.setBudget({month,category: transferId,amount: totalValue + transferValue,@@ -331,7 +331,7 @@ export async function setType(type) {});sheet.get().startCacheBarrier();- sheet.loadUserBudgets(db);+ void sheet.loadUserBudgets(db);const bounds = await createAllBudgets();sheet.get().endCacheBarrier();diff --git a/packages/loot-core/src/server/budget/category-template-context.test.ts b/packages/loot-core/src/server/budget/category-template-context.test.tsindex f5acd097dd..0fd8ad8f13 100644--- a/packages/loot-core/src/server/budget/category-template-context.test.ts+++ b/packages/loot-core/src/server/budget/category-template-context.test.ts@@ -1007,7 +1007,7 @@ describe('CategoryTemplateContext', () => {300,0,);- const result = await instance.getLimitExcess();+ const result = instance.getLimitExcess();expect(result).toBe(0);});@@ -1034,7 +1034,7 @@ describe('CategoryTemplateContext', () => {30000,0,);- const result = await instance.getLimitExcess();+ const result = instance.getLimitExcess();expect(result).toBe(10000);});});diff --git a/packages/loot-core/src/server/budget/goal-template.ts b/packages/loot-core/src/server/budget/goal-template.tsindex 4fbd6666c5..2b78e1b0a9 100644--- a/packages/loot-core/src/server/budget/goal-template.ts+++ b/packages/loot-core/src/server/budget/goal-template.ts@@ -153,7 +153,7 @@ type TemplateBudget = {async function setBudgets(month: string, templateBudget: TemplateBudget[]) {await batchMessages(async () => {templateBudget.forEach(element => {- setBudget({+ void setBudget({category: element.category,month,amount: element.budgeted,@@ -171,7 +171,7 @@ type TemplateGoal = {async function setGoals(month: string, templateGoal: TemplateGoal[]) {await batchMessages(async () => {templateGoal.forEach(element => {- setGoal({+ void setGoal({month,category: element.category,goal: element.goal,@@ -243,7 +243,7 @@ async function processTemplate(//break early if nothing to do, or there are errorsif (templateContexts.length === 0 && errors.length === 0) {if (goalList.length > 0) {- setGoals(month, goalList);+ void setGoals(month, goalList);}return {type: 'message',diff --git a/packages/loot-core/src/server/budgetfiles/app.ts b/packages/loot-core/src/server/budgetfiles/app.tsindex 464c100996..4b7cffe3d4 100644--- a/packages/loot-core/src/server/budgetfiles/app.ts+++ b/packages/loot-core/src/server/budgetfiles/app.ts@@ -260,7 +260,7 @@ async function closeBudget() {clearFullSyncTimeout();await mainApp.stopServices();- await db.closeDatabase();+ db.closeDatabase();try {await asyncStorage.setItem('lastBudget', '');@@ -271,7 +271,7 @@ async function closeBudget() {}prefs.unloadPrefs();- await stopBackupService();+ stopBackupService();return 'ok';}@@ -297,7 +297,7 @@ async function deleteBudget({// way, but works for now.try {await db.openDatabase(id);- await db.closeDatabase();+ db.closeDatabase();const budgetDir = fs.getBudgetDir(id);await fs.removeDirRecursively(budgetDir);} catch {@@ -568,7 +568,7 @@ async function _loadBudget(id: Budget['id']): Promise<{// TODO: The client id should be stored elsewhere. It shouldn't// work this way, but it's fine for now.CRDT.getClock().timestamp.setNode(CRDT.makeClientId());- await db.runQuery(+ db.runQuery('INSERT OR REPLACE INTO messages_clock (id, clock) VALUES (1, ?)',[CRDT.serializeClock(CRDT.getClock())],);@@ -577,7 +577,7 @@ async function _loadBudget(id: Budget['id']): Promise<{}if (!Platform.isBrowser && process.env.NODE_ENV !== 'test') {- await startBackupService(id);+ startBackupService(id);}try {@@ -600,8 +600,8 @@ async function _loadBudget(id: Budget['id']): Promise<{// Load all the in-memory stateawait mappings.loadMappings();await rules.loadRules();- await syncMigrations.listen();- await mainApp.startServices();+ syncMigrations.listen();+ mainApp.startServices();clearUndo();diff --git a/packages/loot-core/src/server/budgetfiles/backups.ts b/packages/loot-core/src/server/budgetfiles/backups.tsindex 82296076b7..241f5ea035 100644--- a/packages/loot-core/src/server/budgetfiles/backups.ts+++ b/packages/loot-core/src/server/budgetfiles/backups.ts@@ -122,9 +122,9 @@ export async function makeBackup(id: string) {await fs.copyFile(fs.join(budgetDir, 'db.sqlite'), backupPath);// Remove all the messages from the backup- const db = sqlite.openDatabase(backupPath);- await sqlite.runQuery(db, 'DELETE FROM messages_crdt');- await sqlite.runQuery(db, 'DELETE FROM messages_clock');+ const db = await sqlite.openDatabase(backupPath);+ sqlite.runQuery(db, 'DELETE FROM messages_crdt');+ sqlite.runQuery(db, 'DELETE FROM messages_clock');sqlite.closeDatabase(db);const toRemove = await updateBackups(await getBackups(id));diff --git a/packages/loot-core/src/server/db/index.ts b/packages/loot-core/src/server/db/index.tsindex 7deeb2348a..a4f4028e12 100644--- a/packages/loot-core/src/server/db/index.ts+++ b/packages/loot-core/src/server/db/index.ts@@ -64,7 +64,7 @@ export function getDatabasePath() {export async function openDatabase(id?: string) {if (db) {- await sqlite.closeDatabase(db);+ sqlite.closeDatabase(db);}dbPath = fs.join(fs.getBudgetDir(id), 'db.sqlite');@@ -73,9 +73,9 @@ export async function openDatabase(id?: string) {// await execQuery('PRAGMA journal_mode = WAL');}-export async function closeDatabase() {+export function closeDatabase() {if (db) {- await sqlite.closeDatabase(db);+ sqlite.closeDatabase(db);setDatabase(null);}}@@ -101,7 +101,7 @@ export async function loadClock() {const clock = makeClock(timestamp);setClock(clock);- await runQuery('INSERT INTO messages_clock (id, clock) VALUES (?, ?)', [+ runQuery('INSERT INTO messages_clock (id, clock) VALUES (?, ?)', [1,serializeClock(clock),]);@@ -171,7 +171,7 @@ export async function all<T>(sql: string, params?: (string | number)[]) {}export async function first<T>(sql, params?: (string | number)[]) {- const arr = await runQuery<T>(sql, params, true);+ const arr = runQuery<T>(sql, params, true);return arr.length === 0 ? null : arr[0];}@@ -190,11 +190,7 @@ export async function run(sql, params?: (string | number)[]) {}export async function select(table, id) {- const rows = await runQuery(- 'SELECT * FROM ' + table + ' WHERE id = ?',- [id],- true,- );+ const rows = runQuery('SELECT * FROM ' + table + ' WHERE id = ?', [id], true);// TODO: In the next phase, we will make this function generic// and pass the type of the return type to `runQuery`.// oxlint-disable-next-line typescript/no-explicit-any@@ -274,7 +270,7 @@ export async function deleteAll(table: string) {}export async function selectWithSchema(table, sql, params) {- const rows = await runQuery(sql, params, true);+ const rows = runQuery(sql, params, true);const convertedRows = rows.map(row => convertFromSelect(schema, schemaConfig, table, row)).filter(Boolean);@@ -771,9 +767,9 @@ export async function moveAccount(const { updates, sort_order } = shoveSortOrders(accounts, targetId);await batchMessages(async () => {for (const info of updates) {- update('accounts', info);+ void update('accounts', info);}- update('accounts', { id, sort_order });+ void update('accounts', { id, sort_order });});}diff --git a/packages/loot-core/src/server/encryption/app.ts b/packages/loot-core/src/server/encryption/app.tsindex dc7c2ae1c7..daa7a2e12f 100644--- a/packages/loot-core/src/server/encryption/app.ts+++ b/packages/loot-core/src/server/encryption/app.ts@@ -105,7 +105,7 @@ async function keyTest({} = JSON.parse(originalTest);const key = await encryption.createKey({ id, password, salt });- encryption.loadKey(key);+ await encryption.loadKey(key);try {await encryption.decrypt(Buffer.from(test.value, 'base64'), test.meta);diff --git a/packages/loot-core/src/server/encryption/encryption-internals.ts b/packages/loot-core/src/server/encryption/encryption-internals.tsindex ea6e99b429..9384da4e3b 100644--- a/packages/loot-core/src/server/encryption/encryption-internals.ts+++ b/packages/loot-core/src/server/encryption/encryption-internals.ts@@ -7,7 +7,7 @@ export function randomBytes(n) {return crypto.randomBytes(n);}-export function encrypt(masterKey, value) {+export async function encrypt(masterKey, value) {const masterKeyBuffer = masterKey.getValue().raw;// let iv = createKeyBuffer({ numBytes: 12, secret: masterKeyBuffer });const iv = crypto.randomBytes(12);@@ -32,7 +32,7 @@ export function encrypt(masterKey, value) {};}-export function decrypt(masterKey, encrypted, meta) {+export async function decrypt(masterKey, encrypted, meta) {const masterKeyBuffer = masterKey.getValue().raw;const { algorithm, iv: originalIv, authTag: originalAuthTag } = meta;const iv = Buffer.from(originalIv, 'base64');@@ -46,7 +46,7 @@ export function decrypt(masterKey, encrypted, meta) {return decrypted;}-export function createKey({ secret, salt }) {+export async function createKey({ secret, salt }) {const buffer = createKeyBuffer({ secret, salt });return {raw: buffer,@@ -54,7 +54,7 @@ export function createKey({ secret, salt }) {};}-export function importKey(str) {+export async function importKey(str) {return {raw: Buffer.from(str, 'base64'),base64: str,diff --git a/packages/loot-core/src/server/encryption/index.ts b/packages/loot-core/src/server/encryption/index.tsindex b4d398a4d6..c38b9c1b30 100644--- a/packages/loot-core/src/server/encryption/index.ts+++ b/packages/loot-core/src/server/encryption/index.ts@@ -50,11 +50,11 @@ export function hasKey(keyId) {return keyId in keys;}-export function encrypt(value, keyId) {+export async function encrypt(value, keyId) {return internals.encrypt(getKey(keyId), value);}-export function decrypt(encrypted, meta) {+export async function decrypt(encrypted, meta) {return internals.decrypt(getKey(meta.keyId), encrypted, meta);}diff --git a/packages/loot-core/src/server/main.test.ts b/packages/loot-core/src/server/main.test.tsindex 8d648e4e4a..e2497788c1 100644--- a/packages/loot-core/src/server/main.test.ts+++ b/packages/loot-core/src/server/main.test.ts@@ -88,7 +88,7 @@ describe('Budgets', () => {await createTestBudget('default-budget-template');await db.openDatabase('test-budget');- await db.runQuery('INSERT INTO __migrations__ (id) VALUES (1000)');+ db.runQuery('INSERT INTO __migrations__ (id) VALUES (1000)');const spy = vi.spyOn(console, 'warn').mockImplementation(() => null);@@ -180,7 +180,7 @@ describe('Budget', () => {// Add a transaction (which needs an account) earlier then the// current earliest budget to test if it creates the necessary// budgets for the earlier months- await db.runQuery("INSERT INTO accounts (id, name) VALUES ('one', 'boa')");+ db.runQuery("INSERT INTO accounts (id, name) VALUES ('one', 'boa')");await runHandler(handlers['transaction-add'], {id: uuidv4(),date: '2016-05-06',@@ -219,18 +219,10 @@ describe('Budget', () => {// Force the system to start tracking these months so budgets are// automatically updated when adding/deleting categories- await db.runQuery('INSERT INTO created_budgets (month) VALUES (?)', [- '2017-01',- ]);- await db.runQuery('INSERT INTO created_budgets (month) VALUES (?)', [- '2017-02',- ]);- await db.runQuery('INSERT INTO created_budgets (month) VALUES (?)', [- '2017-03',- ]);- await db.runQuery('INSERT INTO created_budgets (month) VALUES (?)', [- '2017-04',- ]);+ db.runQuery('INSERT INTO created_budgets (month) VALUES (?)', ['2017-01']);+ db.runQuery('INSERT INTO created_budgets (month) VALUES (?)', ['2017-02']);+ db.runQuery('INSERT INTO created_budgets (month) VALUES (?)', ['2017-03']);+ db.runQuery('INSERT INTO created_budgets (month) VALUES (?)', ['2017-04']);let categories;await captureChangedCells(async () => {@@ -257,7 +249,7 @@ describe('Budget', () => {];});- await db.runQuery("INSERT INTO accounts (id, name) VALUES ('boa', 'boa')");+ db.runQuery("INSERT INTO accounts (id, name) VALUES ('boa', 'boa')");const trans = {id: 'boa-transaction',date: '2017-02-06',diff --git a/packages/loot-core/src/server/main.ts b/packages/loot-core/src/server/main.tsindex 0a2bf21c5b..a7cf6bd3f4 100644--- a/packages/loot-core/src/server/main.ts+++ b/packages/loot-core/src/server/main.ts@@ -120,7 +120,7 @@ handlers['set-server-url'] = async function ({ url, validate = true }) {handlers['app-focused'] = async function () {if (prefs.getPrefs() && prefs.getPrefs().id) {// First we sync- fullSync();+ void fullSync();}};diff --git a/packages/loot-core/src/server/migrate/cli.ts b/packages/loot-core/src/server/migrate/cli.tsindex 665b6c750c..ecdd247378 100755--- a/packages/loot-core/src/server/migrate/cli.ts+++ b/packages/loot-core/src/server/migrate/cli.ts@@ -66,7 +66,7 @@ async function list(db) {const cmd = argv._[0];-withMigrationsDir(argv.m || getMigrationsDir(), async () => {+void withMigrationsDir(argv.m || getMigrationsDir(), async () => {switch (cmd) {case 'reset':fs.unlinkSync(argv.db);@@ -74,10 +74,10 @@ withMigrationsDir(argv.m || getMigrationsDir(), async () => {path.join(__dirname, '../../../src/server/sql/init.sql'),'utf8',);- getDatabase().exec(initSql);+ (await getDatabase()).exec(initSql);break;case 'migrate':- const applied = await migrate(getDatabase());+ const applied = await migrate(await getDatabase());if (applied.length === 0) {logger.log('No pending migrations');} else {@@ -85,7 +85,7 @@ withMigrationsDir(argv.m || getMigrationsDir(), async () => {}break;case 'list':- await list(getDatabase());+ await list(await getDatabase());break;case 'create':default:@@ -94,7 +94,7 @@ withMigrationsDir(argv.m || getMigrationsDir(), async () => {logger.log('Must pass a name for the new migration with --name');process.exit(1);}- await create(name);+ create(name);break;}});diff --git a/packages/loot-core/src/server/migrate/migrations.test.ts b/packages/loot-core/src/server/migrate/migrations.test.tsindex 6cc4467677..acb52ce2ff 100644--- a/packages/loot-core/src/server/migrate/migrations.test.ts+++ b/packages/loot-core/src/server/migrate/migrations.test.ts@@ -45,7 +45,7 @@ describe('Migrations', () => {__dirname + '/../../mocks/migrations',async () => {// Insert a random migration id- await db.runQuery('INSERT INTO __migrations__ (id) VALUES (1000)');+ db.runQuery('INSERT INTO __migrations__ (id) VALUES (1000)');try {await migrate(db.getDatabase());diff --git a/packages/loot-core/src/server/migrate/migrations.ts b/packages/loot-core/src/server/migrate/migrations.tsindex 72147dbfc0..b1daef7303 100644--- a/packages/loot-core/src/server/migrate/migrations.ts+++ b/packages/loot-core/src/server/migrate/migrations.ts@@ -55,17 +55,17 @@ async function patchBadMigrations(db: Database) {const newFiltersMigration = 1688749527273;const appliedIds = await getAppliedMigrations(db);if (appliedIds.includes(badFiltersMigration)) {- await sqlite.runQuery(db, 'DELETE FROM __migrations__ WHERE id = ?', [+ sqlite.runQuery(db, 'DELETE FROM __migrations__ WHERE id = ?', [badFiltersMigration,]);- await sqlite.runQuery(db, 'INSERT INTO __migrations__ (id) VALUES (?)', [+ sqlite.runQuery(db, 'INSERT INTO __migrations__ (id) VALUES (?)', [newFiltersMigration,]);}}export async function getAppliedMigrations(db: Database): Promise<number[]> {- const rows = await sqlite.runQuery<{ id: number }>(+ const rows = sqlite.runQuery<{ id: number }>(db,'SELECT * FROM __migrations__ ORDER BY id ASC',[],@@ -120,7 +120,7 @@ async function applyJavaScript(db, id) {async function applySql(db, sql) {try {- await sqlite.execQuery(db, sql);+ sqlite.execQuery(db, sql);} catch (e) {logger.log('Error applying sql:', sql);throw e;@@ -138,7 +138,7 @@ export async function applyMigration(} else {await applySql(db, code);}- await sqlite.runQuery(db, 'INSERT INTO __migrations__ (id) VALUES (?)', [+ sqlite.runQuery(db, 'INSERT INTO __migrations__ (id) VALUES (?)', [getMigrationId(name),]);}diff --git a/packages/loot-core/src/server/mutators.ts b/packages/loot-core/src/server/mutators.tsindex 6adc867635..c8b3aca179 100644--- a/packages/loot-core/src/server/mutators.ts+++ b/packages/loot-core/src/server/mutators.ts@@ -66,7 +66,7 @@ export async function runHandler<T extends Handlers[keyof Handlers]>(const promise = handler(args);runningMethods.add(promise);- promise.then(() => {+ void promise.then(() => {runningMethods.delete(promise);});return promise as Promise<ReturnType<T>>;diff --git a/packages/loot-core/src/server/schedules/app.ts b/packages/loot-core/src/server/schedules/app.tsindex 060c33f0d2..3f36425f1e 100644--- a/packages/loot-core/src/server/schedules/app.ts+++ b/packages/loot-core/src/server/schedules/app.ts@@ -567,9 +567,9 @@ app.events.on('sync', ({ type }) => {const { lastScheduleRun } = prefs.getPrefs();if (lastScheduleRun !== currentDay()) {- runMutator(() => advanceSchedulesService(type === 'success'));+ void runMutator(() => advanceSchedulesService(type === 'success'));- prefs.savePrefs({ lastScheduleRun: currentDay() });+ void prefs.savePrefs({ lastScheduleRun: currentDay() });}}});diff --git a/packages/loot-core/src/server/sheet.ts b/packages/loot-core/src/server/sheet.tsindex de9a60bd21..a910db2319 100644--- a/packages/loot-core/src/server/sheet.ts+++ b/packages/loot-core/src/server/sheet.ts@@ -26,7 +26,7 @@ export function get(): Spreadsheet {}async function updateSpreadsheetCache(rawDb, names: string[]) {- await sqlite.transaction(rawDb, () => {+ sqlite.transaction(rawDb, () => {names.forEach(name => {const node = globalSheet._getNode(name);@@ -115,7 +115,7 @@ export async function loadSpreadsheet(const cachePath = db.getDatabasePath().replace(/db\.sqlite$/, 'cache.sqlite');- globalCacheDb = cacheDb = sqlite.openDatabase(cachePath);+ globalCacheDb = cacheDb = await sqlite.openDatabase(cachePath);sqlite.execQuery(cacheDb,@@ -152,7 +152,7 @@ export async function loadSpreadsheet(}if (cacheEnabled && !isCacheDirty(mainDb, cacheDb)) {- const cachedRows = await sqlite.runQuery<{ key?: number; value: string }>(+ const cachedRows = sqlite.runQuery<{ key?: number; value: string }>(cacheDb,'SELECT * FROM kvcache',[],diff --git a/packages/loot-core/src/server/spreadsheet/spreadsheet.ts b/packages/loot-core/src/server/spreadsheet/spreadsheet.tsindex 4a921e746b..4f468f75af 100644--- a/packages/loot-core/src/server/spreadsheet/spreadsheet.ts+++ b/packages/loot-core/src/server/spreadsheet/spreadsheet.ts@@ -139,7 +139,7 @@ export class Spreadsheet {// Begin running on the next tick so we guarantee that it doesn't finish// within the same tick. Since some computations are async, this makes it// consistent (otherwise it would only sometimes finish sync)- Promise.resolve().then(() => {+ void Promise.resolve().then(() => {if (!this.running) {this.runComputations();}diff --git a/packages/loot-core/src/server/sync/index.ts b/packages/loot-core/src/server/sync/index.tsindex 245de001be..6cd3ce1c12 100644--- a/packages/loot-core/src/server/sync/index.ts+++ b/packages/loot-core/src/server/sync/index.ts@@ -134,7 +134,7 @@ async function fetchAll(table, ids) {sql += partIds.map(() => `${column} = ?`).join(' OR ');try {- const rows = await db.runQuery(sql, partIds, true);+ const rows = db.runQuery(sql, partIds, true);results = results.concat(rows);} catch (error) {throw new SyncError('invalid-schema', {@@ -362,7 +362,7 @@ export const applyMessages = sequential(async (messages: Message[]) => {// Special treatment for some synced prefsif (dataset === 'preferences' && row === 'budgetType') {- setBudgetType(value);+ void setBudgetType(value);}}@@ -388,7 +388,7 @@ export const applyMessages = sequential(async (messages: Message[]) => {// Save any synced prefsif (Object.keys(prefsToSet).length > 0) {- prefs.savePrefs(prefsToSet, { avoidSync: true });+ void prefs.savePrefs(prefsToSet, { avoidSync: true });connection.send('prefs-updated');}@@ -465,7 +465,7 @@ async function _sendMessages(messages: Message[]): Promise<void> {try {await applyMessages(messages);} catch (e) {- errorHandler(e);+ void errorHandler(e);throw e;}@@ -486,7 +486,7 @@ export async function batchMessages(func: () => Promise<void>): Promise<void> {try {await func();} catch (e) {- errorHandler(e);+ void errorHandler(e);throw e;} finally {IS_BATCHING = false;@@ -621,7 +621,7 @@ export const fullSync = once(async function (): Promise<app.events.emit('sync', { type: 'unauthorized' });// Set the user into read-only mode- asyncStorage.setItem('readOnly', 'true');+ void asyncStorage.setItem('readOnly', 'true');} else if (e.reason === 'network-failure') {app.events.emit('sync', { type: 'error', subtype: 'network' });} else {diff --git a/packages/loot-core/src/server/sync/make-test-message.ts b/packages/loot-core/src/server/sync/make-test-message.tsindex 6878e41cac..7415d14005 100644--- a/packages/loot-core/src/server/sync/make-test-message.ts+++ b/packages/loot-core/src/server/sync/make-test-message.ts@@ -3,16 +3,16 @@ import { SyncProtoBuf } from '@actual-app/crdt';import * as encryption from '../encryption';-async function randomString() {- return (await encryption.randomBytes(12)).toString();+function randomString() {+ return encryption.randomBytes(12).toString();}export async function makeTestMessage(keyId) {const messagePb = new SyncProtoBuf.Message();- messagePb.setDataset(await randomString());- messagePb.setRow(await randomString());- messagePb.setColumn(await randomString());- messagePb.setValue(await randomString());+ messagePb.setDataset(randomString());+ messagePb.setRow(randomString());+ messagePb.setColumn(randomString());+ messagePb.setValue(randomString());const binaryMsg = messagePb.serializeBinary();return await encryption.encrypt(binaryMsg, keyId);diff --git a/packages/loot-core/src/server/sync/migrate.test.ts b/packages/loot-core/src/server/sync/migrate.test.tsindex 8acc0c8d70..583692ca60 100644--- a/packages/loot-core/src/server/sync/migrate.test.ts+++ b/packages/loot-core/src/server/sync/migrate.test.ts@@ -45,7 +45,7 @@ const messageArb: fc.Arbitrary<Message> = fc),).map(date => date.toISOString() + '-0000-0123456789ABCDEF')- .map(Timestamp.parse);+ .map(ts => Timestamp.parse(ts));return fc.record<Message>({timestamp,@@ -80,7 +80,7 @@ describe('sync migrations', () => {amount: 4500,});tracer.expectNow('applied', ['trans1/child1']);- await tracer.expectWait('applied', ['trans1/child1']);+ tracer.expectNow('applied', ['trans1/child1']);const transactions = db.runQuery<db.DbTransaction>('SELECT * FROM transactions',diff --git a/packages/loot-core/src/server/sync/migrate.ts b/packages/loot-core/src/server/sync/migrate.tsindex 827655f6bb..9b9a737d29 100644--- a/packages/loot-core/src/server/sync/migrate.ts+++ b/packages/loot-core/src/server/sync/migrate.ts@@ -28,7 +28,7 @@ function migrateParentIds(_oldValues, newValues) {});if (toApply.length > 0) {- applyMessages(toApply);+ void applyMessages(toApply);}}});diff --git a/packages/loot-core/src/server/sync/reset.ts b/packages/loot-core/src/server/sync/reset.tsindex c4b65bc606..5bfa645995 100644--- a/packages/loot-core/src/server/sync/reset.ts+++ b/packages/loot-core/src/server/sync/reset.ts@@ -33,7 +33,7 @@ export async function resetSync(//// Be VERY careful here since we are bulk deleting data. It should// never delete any data that doesn't have `tombstone = 1`- await db.execQuery(`+ db.execQuery(`DELETE FROM messages_crdt;DELETE FROM messages_clock;DELETE FROM transactions WHERE tombstone = 1;diff --git a/packages/loot-core/src/server/sync/sync.property.test.ts b/packages/loot-core/src/server/sync/sync.property.test.tsindex 0ea75df07f..8749a9153c 100644--- a/packages/loot-core/src/server/sync/sync.property.test.ts+++ b/packages/loot-core/src/server/sync/sync.property.test.ts@@ -225,8 +225,8 @@ async function run(msgs) {{ firstMessages: [], secondMessages: [] },);- prefs.loadPrefs();- prefs.savePrefs({+ void prefs.loadPrefs();+ void prefs.savePrefs({groupId: 'group',lastSyncedTimestamp: new Timestamp(Date.now(),@@ -313,7 +313,7 @@ async function run(msgs) {describe('sync property test', () => {it.skip('should always sync clients into the same state', async () => {- const test = await jsc.check(+ const test = jsc.check(jsc.forall(jsc.tuple(Array.from(new Array(100)).map(() => jsc.oneof(generators))),async msgs => {diff --git a/packages/loot-core/src/server/sync/sync.test.ts b/packages/loot-core/src/server/sync/sync.test.tsindex d96dd35a9e..40d7c6eea3 100644--- a/packages/loot-core/src/server/sync/sync.test.ts+++ b/packages/loot-core/src/server/sync/sync.test.ts@@ -24,8 +24,8 @@ afterEach(() => {describe('Sync', () => {it('should send messages to the server', async () => {- prefs.loadPrefs();- prefs.savePrefs({ groupId: 'group' });+ void prefs.loadPrefs();+ void prefs.savePrefs({ groupId: 'group' });let timestamp = Timestamp.send();await sendMessages([@@ -63,8 +63,8 @@ describe('Sync', () => {});it('should resend old messages to the server', async () => {- prefs.loadPrefs();- prefs.savePrefs({ groupId: 'group' });+ void prefs.loadPrefs();+ void prefs.savePrefs({ groupId: 'group' });global.stepForwardInTime(Date.parse('2018-11-13T13:20:00.000Z'));@@ -88,7 +88,9 @@ describe('Sync', () => {// Move the clock forward so that the above 2 messages are not// automatically sent out, but will need to be re-sent by way of// the merkle tree- prefs.savePrefs({ lastSyncedTimestamp: getClock().timestamp.toString() });+ void prefs.savePrefs({+ lastSyncedTimestamp: getClock().timestamp.toString(),+ });expect(mockSyncServer.getMessages().length).toBe(0);@@ -99,8 +101,8 @@ describe('Sync', () => {});it('should sync multiple clients', async () => {- prefs.loadPrefs();- prefs.savePrefs({+ void prefs.loadPrefs();+ void prefs.savePrefs({groupId: 'group',lastSyncedTimestamp: Timestamp.zero.toString(),});@@ -150,7 +152,7 @@ describe('Sync', () => {});});-async function registerBudgetMonths(months) {+function registerBudgetMonths(months) {const createdMonths = new Set();for (const month of months) {createdMonths.add(month);@@ -159,8 +161,8 @@ async function registerBudgetMonths(months) {}async function asSecondClient(func) {- prefs.loadPrefs();- prefs.savePrefs({+ void prefs.loadPrefs();+ void prefs.savePrefs({groupId: 'group',lastSyncedTimestamp: Timestamp.zero.toString(),});@@ -168,7 +170,7 @@ async function asSecondClient(func) {await func();await global.emptyDatabase()();- prefs.savePrefs({+ void prefs.savePrefs({groupId: 'group',lastSyncedTimestamp: Timestamp.zero.toString(),});diff --git a/packages/loot-core/src/server/transactions/import/parse-file.test.ts b/packages/loot-core/src/server/transactions/import/parse-file.test.tsindex f976981bbf..9d6c0b0007 100644--- a/packages/loot-core/src/server/transactions/import/parse-file.test.ts+++ b/packages/loot-core/src/server/transactions/import/parse-file.test.ts@@ -31,7 +31,7 @@ type Transaction = {};async function getTransactions(accountId: string): Promise<Transaction[]> {- return await db.runQuery(+ return db.runQuery('SELECT * FROM transactions WHERE acct = ?',[accountId],true,@@ -73,7 +73,7 @@ async function importFileWithRealTime(describe('File import', () => {test('qif import works', async () => {- prefs.loadPrefs();+ await prefs.loadPrefs();await db.insertAccount({ id: 'one', name: 'one' });const { errors } = await importFileWithRealTime('one',@@ -86,7 +86,7 @@ describe('File import', () => {});test('ofx import works', async () => {- prefs.loadPrefs();+ await prefs.loadPrefs();await db.insertAccount({ id: 'one', name: 'one' });const { errors } = await importFileWithRealTime(@@ -100,7 +100,7 @@ describe('File import', () => {}, 45000);test('ofx import works (credit card)', async () => {- prefs.loadPrefs();+ await prefs.loadPrefs();await db.insertAccount({ id: 'one', name: 'one' });const { errors } = await importFileWithRealTime(@@ -114,7 +114,7 @@ describe('File import', () => {}, 45000);test('qfx import works', async () => {- prefs.loadPrefs();+ await prefs.loadPrefs();await db.insertAccount({ id: 'one', name: 'one' });const { errors } = await importFileWithRealTime(@@ -128,7 +128,7 @@ describe('File import', () => {}, 45000);test('import notes are respected when importing', async () => {- prefs.loadPrefs();+ await prefs.loadPrefs();await db.insertAccount({ id: 'one', name: 'one' });// Test with importNotes enabled@@ -144,7 +144,7 @@ describe('File import', () => {);// Clear transactions- await db.runQuery('DELETE FROM transactions WHERE acct = ?', ['one']);+ db.runQuery('DELETE FROM transactions WHERE acct = ?', ['one']);// Test with importNotes disabledconst { errors: errorsWithoutNotes } = await importFileWithRealTime(@@ -159,7 +159,7 @@ describe('File import', () => {}, 45000);test('matches extensions correctly (case-insensitive, etc)', async () => {- prefs.loadPrefs();+ await prefs.loadPrefs();await db.insertAccount({ id: 'one', name: 'one' });let res = await importFileWithRealTime(@@ -181,7 +181,7 @@ describe('File import', () => {}, 45000);test('handles non-ASCII characters', async () => {- prefs.loadPrefs();+ await prefs.loadPrefs();await db.insertAccount({ id: 'one', name: 'one' });const { errors } = await importFileWithRealTime(@@ -195,7 +195,7 @@ describe('File import', () => {});test('handles html escaped plaintext', async () => {- prefs.loadPrefs();+ await prefs.loadPrefs();await db.insertAccount({ id: 'one', name: 'one' });const { errors } = await importFileWithRealTime(@@ -209,7 +209,7 @@ describe('File import', () => {});test('CAMT.053 import works', async () => {- prefs.loadPrefs();+ await prefs.loadPrefs();await db.insertAccount({ id: 'one', name: 'one' });const { errors } = await importFileWithRealTime(diff --git a/packages/loot-core/src/server/transactions/merge.test.ts b/packages/loot-core/src/server/transactions/merge.test.tsindex cf9e959c0b..08972fabb8 100644--- a/packages/loot-core/src/server/transactions/merge.test.ts+++ b/packages/loot-core/src/server/transactions/merge.test.ts@@ -34,9 +34,9 @@ describe('Merging fails for invalid quantity', () => {date: '2025-01-01',amount: 12,});- expect(() => mergeTransactions([{ id: t1 }, { id: t2 }])).rejects.toThrow(- 'Transaction amounts must match for merge',- );+ await expect(() =>+ mergeTransactions([{ id: t1 }, { id: t2 }]),+ ).rejects.toThrow('Transaction amounts must match for merge');});it("fails when transaction id doesn't exist", async () => {@@ -46,7 +46,7 @@ describe('Merging fails for invalid quantity', () => {date: '2025-01-01',amount: 10,});- expect(() =>+ await expect(() =>mergeTransactions([{ id: t1 }, { id: 'missing' }]),).rejects.toThrow('One of the provided transactions does not exist');});diff --git a/packages/loot-core/src/server/update.ts b/packages/loot-core/src/server/update.tsindex 9caf6d3e19..a8541a4144 100644--- a/packages/loot-core/src/server/update.ts+++ b/packages/loot-core/src/server/update.ts@@ -23,11 +23,11 @@ async function updateViews() {const currentHash = md5(views);if (hash !== currentHash) {- await db.execQuery(views);- await db.runQuery(- 'INSERT OR REPLACE INTO __meta__ (key, value) VALUES (?, ?)',- [hashKey, currentHash],- );+ db.execQuery(views);+ db.runQuery('INSERT OR REPLACE INTO __meta__ (key, value) VALUES (?, ?)', [+ hashKey,+ currentHash,+ ]);}}diff --git a/packages/loot-core/src/shared/async.test.ts b/packages/loot-core/src/shared/async.test.tsindex dd9c017add..1fbe5fe6f5 100644--- a/packages/loot-core/src/shared/async.test.ts+++ b/packages/loot-core/src/shared/async.test.ts@@ -81,7 +81,7 @@ describe('async', () => {const data = [];const fn = sequential(makeFunction(data));- fn(1).then(() => {+ void fn(1).then(() => {// The next call should already have started (so it should have// already appended 2 to the end). It shouldn't depend on this// promise chain at all (important part being that if any errorsdiff --git a/packages/loot-core/src/shared/schedules.test.ts b/packages/loot-core/src/shared/schedules.test.tsindex 7f8bd15b9a..abcb64834e 100644--- a/packages/loot-core/src/shared/schedules.test.ts+++ b/packages/loot-core/src/shared/schedules.test.ts@@ -13,7 +13,7 @@ import {} from './schedules';import type { ScheduleStatuses } from './schedules';-i18next.init({+void i18next.init({lng: 'en',fallbackLng: 'en',resources: {diff --git a/packages/plugins-service/src/plugin-service-worker.ts b/packages/plugins-service/src/plugin-service-worker.tsindex f63f43220f..e244e77033 100644--- a/packages/plugins-service/src/plugin-service-worker.ts+++ b/packages/plugins-service/src/plugin-service-worker.ts@@ -32,9 +32,9 @@ self.addEventListener('install', (_event: ExtendableEvent) => {// Log activation eventself.addEventListener('activate', (_event: ExtendableEvent) => {- self.clients.claim();+ void self.clients.claim();- self.clients.matchAll().then(clients => {+ void self.clients.matchAll().then(clients => {clients.forEach(client => {client.postMessage({type: 'service-worker-ready',@@ -46,7 +46,7 @@ self.addEventListener('activate', (_event: ExtendableEvent) => {self.addEventListener('message', (event: ExtendableMessageEvent) => {if (event.data && (event.data as PluginMessage).type === 'SKIP_WAITING') {- self.skipWaiting();+ void self.skipWaiting();}});diff --git a/packages/sync-server/app.ts b/packages/sync-server/app.tsindex 1c788f84f3..320d5d47c5 100644--- a/packages/sync-server/app.ts+++ b/packages/sync-server/app.ts@@ -3,7 +3,7 @@ import { run as runMigrations } from './src/migrations';runMigrations().then(() => {//import the app here becasue initial migrations need to be run first - they are dependencies of the app.js- import('./src/app.js').then(app => app.run()); // run the app+ void import('./src/app.js').then(app => app.run()); // run the app}).catch(err => {console.log('Error starting app:', err);diff --git a/packages/sync-server/bin/actual-server.js b/packages/sync-server/bin/actual-server.jsindex 0f59da406a..be20770de1 100755--- a/packages/sync-server/bin/actual-server.js+++ b/packages/sync-server/bin/actual-server.js@@ -123,4 +123,4 @@ if (values['reset-password']) {}// start the sync server-import('../app.js');+void import('../app.js');diff --git a/packages/sync-server/bin/add-import-extensions.mjs b/packages/sync-server/bin/add-import-extensions.mjsindex 4005b2a604..1f5533e780 100644--- a/packages/sync-server/bin/add-import-extensions.mjs+++ b/packages/sync-server/bin/add-import-extensions.mjs@@ -99,4 +99,4 @@ async function main() {}}-main();+void main();diff --git a/packages/sync-server/src/account-db.js b/packages/sync-server/src/account-db.jsindex 0be5daca69..46a8f1baad 100644--- a/packages/sync-server/src/account-db.js+++ b/packages/sync-server/src/account-db.js@@ -180,7 +180,7 @@ export async function disableOpenID(loginSettings) {}}- const { error } = (await bootstrapPassword(loginSettings.password)) || {};+ const { error } = bootstrapPassword(loginSettings.password) || {};if (error) {return { error };}diff --git a/packages/sync-server/src/app-sync.test.ts b/packages/sync-server/src/app-sync.test.tsindex 419864b94b..e4075f7217 100644--- a/packages/sync-server/src/app-sync.test.ts+++ b/packages/sync-server/src/app-sync.test.ts@@ -301,7 +301,7 @@ describe('/upload-user-file', () => {],);- await fs.writeFile(getPathForUserFile(fileId), oldFileContent, err => {+ fs.writeFile(getPathForUserFile(fileId), oldFileContent, err => {if (err) throw err;});diff --git a/packages/sync-server/src/scripts/reset-password.js b/packages/sync-server/src/scripts/reset-password.jsindex 32d728a7e5..9fb275f9c4 100644--- a/packages/sync-server/src/scripts/reset-password.js+++ b/packages/sync-server/src/scripts/reset-password.js@@ -29,7 +29,7 @@ if (needsBootstrap()) {console.log("It looks like you already have a password set. Let's reset it!");try {const password = await promptPassword();- const { error } = await changePassword(password);+ const { error } = changePassword(password);if (error) {console.log('Error changing password:', error);console.log(diff --git a/upcoming-release-notes/6987.md b/upcoming-release-notes/6987.mdnew file mode 100644index 0000000000..993d57aae1--- /dev/null+++ b/upcoming-release-notes/6987.md@@ -0,0 +1,6 @@+---+category: Maintenance+authors: [MatissJanis]+---++lint: fix typescript/await-thenable and typescript/no-floating-promises issues