diff --git a/src/plugins/betterGifAltText/index.ts b/src/plugins/betterGifAltText/index.ts index f07295704..8b4116318 100644 --- a/src/plugins/betterGifAltText/index.ts +++ b/src/plugins/betterGifAltText/index.ts @@ -45,7 +45,8 @@ export default definePlugin({ ], altify(props: any) { - if (props.alt && props.alt !== "GIF") return props.alt; + props.alt ??= "GIF"; + if (props.alt !== "GIF") return props.alt; let url: string = props.original || props.src; try {