Skip to content

Commit

Permalink
fix: Only reset preview src if it used to fail before
Browse files Browse the repository at this point in the history
Signed-off-by: Julius Härtl <jus@bitgrid.net>
  • Loading branch information
juliushaertl committed Nov 13, 2023
1 parent eaaf954 commit 0d2e9a1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions apps/files/src/components/FileEntry/FileEntryPreview.vue
Expand Up @@ -217,11 +217,11 @@ export default Vue.extend({
methods: {
reset() {
// Reset background state
this.backgroundFailed = undefined
if (this.$refs.previewImg) {
if (this.backgroundFailed === true && this.$refs.previewImg) {
this.$refs.previewImg.src = ''
}
// Reset background state
this.backgroundFailed = undefined
},
t,
Expand Down

0 comments on commit 0d2e9a1

Please sign in to comment.