diff options
author | Ferdinand Thiessen <opensource@fthiessen.de> | 2024-01-27 01:19:12 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-27 01:19:12 +0100 |
commit | af78145e21ed1fd2010b630ba4c3802a56b368a8 (patch) | |
tree | f77b2bf8e0f6a37291821230e85b2f6fe978a0e9 /apps | |
parent | b0c003d7bed709ccb1bf95aec6cac25378d57fd1 (diff) | |
parent | 4b3e6eabab4b112135ea955929c165371ef066e3 (diff) | |
download | nextcloud-server-af78145e21ed1fd2010b630ba4c3802a56b368a8.tar.gz nextcloud-server-af78145e21ed1fd2010b630ba4c3802a56b368a8.zip |
Merge pull request #43150 from nextcloud/backport/43148/stable28
[stable28] Update `@nextcloud/dialogs` to 5.1.1
Diffstat (limited to 'apps')
-rw-r--r-- | apps/files/src/actions/moveOrCopyAction.ts | 8 |
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'))) + } }) }) } |