aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorFerdinand Thiessen <opensource@fthiessen.de>2024-01-26 14:44:51 +0100
committerFerdinand Thiessen <opensource@fthiessen.de>2024-01-27 01:21:00 +0100
commitc089214a2a4bc178d0c6da63ed7d579b92523448 (patch)
tree68043fabd2696b2bdda7233d74f72d8914103ebb /apps
parent764f34c4f6516fd88621cca3355d09e429257bd7 (diff)
downloadnextcloud-server-c089214a2a4bc178d0c6da63ed7d579b92523448.tar.gz
nextcloud-server-c089214a2a4bc178d0c6da63ed7d579b92523448.zip
chore: Update `@nextcloud/dialogs` to 5.1.1
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
Diffstat (limited to 'apps')
-rw-r--r--apps/files/src/actions/moveOrCopyAction.ts8
1 files changed, 6 insertions, 2 deletions
diff --git a/apps/files/src/actions/moveOrCopyAction.ts b/apps/files/src/actions/moveOrCopyAction.ts
index a4e70caf37d..7fa899dc7da 100644
--- a/apps/files/src/actions/moveOrCopyAction.ts
+++ b/apps/files/src/actions/moveOrCopyAction.ts
@@ -29,7 +29,7 @@ import type { MoveCopyResult } from './moveOrCopyActionUtils'
import { AxiosError } from 'axios'
import { basename, join } from 'path'
import { emit } from '@nextcloud/event-bus'
-import { getFilePickerBuilder, showError } from '@nextcloud/dialogs'
+import { FilePickerClosed, getFilePickerBuilder, showError } from '@nextcloud/dialogs'
import { Permission, FileAction, FileType, NodeStatus, davGetClient, davRootPath, davResultToNode, davGetDefaultPropfind } from '@nextcloud/files'
import { translate as t } from '@nextcloud/l10n'
import Vue from 'vue'
@@ -232,7 +232,11 @@ const openFilePickerForAction = async (action: MoveCopyAction, dir = '/', nodes:
const picker = filePicker.build()
picker.pick().catch((error) => {
logger.debug(error as Error)
- reject(new Error(t('files', 'Cancelled move or copy operation')))
+ if (error instanceof FilePickerClosed) {
+ reject(new Error(t('files', 'Cancelled move or copy operation')))
+ } else {
+ reject(new Error(t('files', 'Move or copy operation failed')))
+ }
})
})
}