webapp: Fix exception on file upload select

This commit is contained in:
Thomas Basler
2025-09-04 17:44:41 +02:00
parent f1b1bd4111
commit 45e1f56486

View File

@@ -265,8 +265,9 @@ export default defineComponent({
const target = this.$refs.file as HTMLInputElement;
if (target.files !== null && target.files[0]) {
this.file = target.files[0];
} else {
return;
}
if (!this.file) return;
// Read the file content
const reader = new FileReader();