Skip to content

There can be more than Notion and Miro. AFFiNE(pronounced [ə‘fain]) is a next-gen knowledge base that brings planning, sorting and creating all together. Privacy first, open-source, customizable and ready to use.

fix(hooks): push success toast after save (#4830)

fourdimf1e32aab6611
diff --git a/packages/frontend/core/src/hooks/affine/use-export-page.ts b/packages/frontend/core/src/hooks/affine/use-export-page.ts
index 0cab4d4b30..ce0a7498ab 100644
--- a/packages/frontend/core/src/hooks/affine/use-export-page.ts
+++ b/packages/frontend/core/src/hooks/affine/use-export-page.ts
@@ -37,7 +37,7 @@ interface ExportHandlerOptions {
async function exportHandler({ page, type }: ExportHandlerOptions) {
if (type === 'pdf' && environment.isDesktop && page.meta.mode === 'page') {
- window.apis?.export.savePDFFileAs(
+ await window.apis?.export.savePDFFileAs(
(page.root as PageBlockModel).title.toString()
);
} else {