fix: Add Check for string before rendering image
continuous-integration/drone/push Build is passing Details

main
Flycro 2024-03-21 12:14:22 +01:00
parent f52415346e
commit 20d03b385b
1 changed files with 1 additions and 1 deletions

View File

@ -144,7 +144,7 @@ async function onSubmit(event: FormSubmitEvent<any>) {
<UFormGroup label="Beschreibung" name="description">
<UTextarea v-model="state.description" />
</UFormGroup>
<img v-if="state.cover_image" :src="$storage(state.cover_image)" alt="Cover" class="size-1/3 content-center rounded-lg">
<img v-if="state.cover_image && typeof state.cover_image === 'string'" :src="$storage(state.cover_image)" alt="Cover" class="size-1/3 content-center rounded-lg">
<UFormGroup label="Cover" name="cover_image">
<UInput type="file" @change="handleCoverImageInput" />
</UFormGroup>