fix linting
This commit is contained in:
@@ -31,7 +31,7 @@
|
||||
"@nymproject/mui-theme": "^1.0.0",
|
||||
"@nymproject/react": "^1.0.0",
|
||||
"@nymproject/types": "^1.0.0",
|
||||
"@nymproject/node-tester": ">=1.2.0-rc.5 || ^1",
|
||||
"@nymproject/node-tester": ">=1.2.0-rc.8",
|
||||
"@storybook/react": "^6.5.15",
|
||||
"@tauri-apps/api": "^1.2.0",
|
||||
"@tauri-apps/tauri-forage": "^1.0.0-beta.2",
|
||||
|
||||
@@ -36,7 +36,19 @@ export const MockAccountsProvider: FCWithChildren = ({ children }) => {
|
||||
password: string;
|
||||
account: AccountEntry;
|
||||
newAccountName: string;
|
||||
}) => {};
|
||||
}) => {
|
||||
if (password) {
|
||||
setIsLoading(true);
|
||||
try {
|
||||
setAccounts((accs) => accs.map((acc) => (acc.id === account.id ? { ...acc, id: newAccountName } : acc)));
|
||||
setDialogToDisplay('Accounts');
|
||||
} catch (e) {
|
||||
setError(`Error adding account: ${e}`);
|
||||
} finally {
|
||||
setIsLoading(false);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
const handleImportAccount = (account: AccountEntry) => setAccounts((accs) => [...(accs ? [...accs] : []), account]);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user