From 5eba7b2360bde2e80780e983afc978627339833a Mon Sep 17 00:00:00 2001 From: iskaktoltay Date: Wed, 9 Oct 2024 13:10:50 +0500 Subject: [PATCH] Changed error and success messages --- frontend/apps/desktop/src/main.ts | 8 ++++---- frontend/apps/desktop/src/save-markdown-file.tsx | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/frontend/apps/desktop/src/main.ts b/frontend/apps/desktop/src/main.ts index 3a4622161..8beff5bfe 100644 --- a/frontend/apps/desktop/src/main.ts +++ b/frontend/apps/desktop/src/main.ts @@ -170,7 +170,7 @@ ipcMain.on( let success: {success: boolean; message: string} = { success: true, - message: `Export successful at: ${filePath}`, + message: `Successfully exported documents to: ${filePath}.`, } for (const {title, markdown} of documents) { @@ -280,7 +280,7 @@ ipcMain.on( } catch (err) { success = { success: false, - message: `Error processing media files: ${err.message || err}`, + message: `Error processing media files: ${err.message || err}.`, } error('Error processing media files:', err) } @@ -293,7 +293,7 @@ ipcMain.on( success: false, message: `Error saving document "${title}": ${ err.message || err - }`, + }.`, } error('Error saving file:', err) return @@ -316,7 +316,7 @@ ipcMain.on( } else { event.sender.send('export-completed', { success: false, - message: 'Export cancelled', + message: 'Export has been cancelled.', }) } }, diff --git a/frontend/apps/desktop/src/save-markdown-file.tsx b/frontend/apps/desktop/src/save-markdown-file.tsx index 0c24f2d0e..e47a59c61 100644 --- a/frontend/apps/desktop/src/save-markdown-file.tsx +++ b/frontend/apps/desktop/src/save-markdown-file.tsx @@ -45,7 +45,7 @@ export async function saveMarkdownFile( let updatedMarkdownContent = markdownContent let success: {success: boolean; message: string} = { success: true, - message: `Export successful at: ${filePath}`, + message: `Successfully exported documents to: ${filePath}.`, } const uploadMediaFile = ({ @@ -116,7 +116,7 @@ export async function saveMarkdownFile( } catch (err) { success = { success: false, - message: `Error processing media files: ${err.message || err}`, + message: `Error processing media files: ${err.message || err}.`, } error('Error processing media files:', err) } @@ -127,7 +127,7 @@ export async function saveMarkdownFile( if (err) { success = { success: false, - message: `Error saving document "${title}": ${err.message || err}`, + message: `Error saving document "${title}": ${err.message || err}.`, } error('Error saving file:', err) return @@ -148,7 +148,7 @@ export async function saveMarkdownFile( } else { event.sender.send('export-completed', { success: false, - message: 'Export cancelled', + message: 'Export has been cancelled.', }) } }