Skip to content

Bring projects, wikis, and teams together with AI. AppFlowy is the AI collaborative workspace where you achieve more without losing control of your data. The leading open source Notion alternative.

chore: replace close_document with close_view (#5033)

Lucas.Xu682f2a6a3be3
diff --git a/frontend/appflowy_flutter/lib/plugins/document/application/doc_service.dart b/frontend/appflowy_flutter/lib/plugins/document/application/doc_service.dart
index 7c7f09ddf6..cf60a3c474 100644
--- a/frontend/appflowy_flutter/lib/plugins/document/application/doc_service.dart
+++ b/frontend/appflowy_flutter/lib/plugins/document/application/doc_service.dart
@@ -56,8 +56,8 @@ class DocumentService {
Future<FlowyResult<void, FlowyError>> closeDocument({
required ViewPB view,
}) async {
- final payload = CloseDocumentPayloadPB()..documentId = view.id;
- final result = await DocumentEventCloseDocument(payload).send();
+ final payload = ViewIdPB()..value = view.id;
+ final result = await FolderEventCloseView(payload).send();
return result;
}