mirror of
https://github.com/nextcloud/server.git
synced 2026-03-04 18:28:08 +01:00
Merge pull request #39950 from nextcloud/bugfix/uncaught-preview-promise
This commit is contained in:
@@ -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}', {
|
||||
|
||||
4
dist/files-main.js
vendored
4
dist/files-main.js
vendored
File diff suppressed because one or more lines are too long
2
dist/files-main.js.map
vendored
2
dist/files-main.js.map
vendored
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user