Optimize application flow (#196)

Co-authored-by: AceDataCloud <office@acedata.cloud>
This commit is contained in:
GermeyandAceDataCloud authored and GitHub committed 2025-03-03 00:57:36 +08:00
1 parent a37f796c81
commit 8ad9637b86
59 files changed
+1573 -1380

No files matched your search

+2 -1
View File
@@ -44,7 +44,7 @@ export const setFingerprint = ({ commit }: ActionContext<IRootState, IRootState>
commit('setFingerprint', payload);
};
export const getUser = async ({ commit }: ActionContext<IRootState, IRootState>): Promise<IUser> => {
export const getUser = async ({ commit }: ActionContext<IRootState, IRootState>): Promise<IUser | undefined> => {
console.debug('start to get user');
try {
commit('resetUser');
@@ -54,6 +54,7 @@ export const getUser = async ({ commit }: ActionContext<IRootState, IRootState>)
return user;
} catch (error) {
console.error('get user failed', error);
return undefined;
}
};