mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-18 23:07:02 +08:00
fix: add @typescript-eslint/no-floating-promises rule (#2764)
Co-authored-by: himself65 <himself65@outlook.com>
This commit is contained in:
@@ -174,7 +174,9 @@ export const CurrentWorkspaceContext = ({
|
||||
useEffect(() => {
|
||||
const id = setTimeout(() => {
|
||||
if (!exist) {
|
||||
void push('/');
|
||||
push('/').catch(err => {
|
||||
console.error(err);
|
||||
});
|
||||
globalThis.HALTING_PROBLEM_TIMEOUT <<= 1;
|
||||
}
|
||||
}, globalThis.HALTING_PROBLEM_TIMEOUT);
|
||||
@@ -319,7 +321,9 @@ export const WorkspaceLayoutInner: FC<PropsWithChildren> = ({ children }) => {
|
||||
}
|
||||
if (!router.query.pageId) {
|
||||
setCurrentPageId(pageId);
|
||||
void jumpToPage(currentWorkspace.id, pageId);
|
||||
jumpToPage(currentWorkspace.id, pageId).catch(err => {
|
||||
console.error(err);
|
||||
});
|
||||
}
|
||||
}
|
||||
//#endregion
|
||||
@@ -353,7 +357,9 @@ export const WorkspaceLayoutInner: FC<PropsWithChildren> = ({ children }) => {
|
||||
}
|
||||
);
|
||||
setCurrentPageId(currentPageId);
|
||||
void jumpToPage(currentWorkspace.id, page.id);
|
||||
jumpToPage(currentWorkspace.id, page.id).catch(err => {
|
||||
console.error(err);
|
||||
});
|
||||
}
|
||||
}, [
|
||||
currentPageId,
|
||||
|
||||
Reference in New Issue
Block a user