aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorJulius Härtl <jus@bitgrid.net>2023-08-22 17:35:45 +0200
committerGitHub <noreply@github.com>2023-08-22 17:35:45 +0200
commit2bb48a6dc7ece023af003ee2a15b433c8bdbe189 (patch)
tree792dc29d402d95af2d30ccbd8d8a9dd2ff9feb60 /apps
parent613cd16583f4db65edeee3f1de8bd340c0a0c5d9 (diff)
parent79c240a17f7ba8205ee1c0a66c9cbb7c9f8b8eec (diff)
downloadnextcloud-server-2bb48a6dc7ece023af003ee2a15b433c8bdbe189.tar.gz
nextcloud-server-2bb48a6dc7ece023af003ee2a15b433c8bdbe189.zip
Merge pull request #39950 from nextcloud/bugfix/uncaught-preview-promise
Diffstat (limited to 'apps')
-rw-r--r--apps/files/src/components/FileEntry.vue6
1 files changed, 5 insertions, 1 deletions
diff --git a/apps/files/src/components/FileEntry.vue b/apps/files/src/components/FileEntry.vue
index 7aaa43c6c01..9384a4bf5e6 100644
--- a/apps/files/src/components/FileEntry.vue
+++ b/apps/files/src/components/FileEntry.vue
@@ -170,7 +170,7 @@ import { CancelablePromise } from 'cancelable-promise'
import { debounce } from 'debounce'
import { emit } from '@nextcloud/event-bus'
import { extname } from 'path'
-import { formatFileSize, Permission } from '@nextcloud/files'
+import { formatFileSize, FileType, Permission } from '@nextcloud/files'
import { generateUrl } from '@nextcloud/router'
import { showError, showSuccess } from '@nextcloud/dialogs'
import { translate } from '@nextcloud/l10n'
@@ -395,6 +395,10 @@ export default Vue.extend({
return this.userConfig.crop_image_previews
},
previewUrl() {
+ if (this.source.type === FileType.Folder) {
+ return null
+ }
+
try {
const previewUrl = this.source.attributes.previewUrl
|| generateUrl('/core/preview?fileId={fileid}', {