fix: Only reset preview src if it used to fail before

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl 2023-11-13 13:00:30 +01:00
parent eaaf954753
commit 0d2e9a1b0a

View file

@ -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,