rename: client -> frontend
This commit is contained in:
parent
db6fff6f26
commit
9384f5399d
592 changed files with 111 additions and 111 deletions
7
packages/frontend/src/scripts/get-account-from-id.ts
Normal file
7
packages/frontend/src/scripts/get-account-from-id.ts
Normal file
|
@ -0,0 +1,7 @@
|
|||
import { get } from '@/scripts/idb-proxy';
|
||||
|
||||
export async function getAccountFromId(id: string) {
|
||||
const accounts = await get('accounts') as { token: string; id: string; }[];
|
||||
if (!accounts) console.log('Accounts are not recorded');
|
||||
return accounts.find(account => account.id === id);
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue