fix: added spoiler type check

pull/785/head
Skythrew 2022-09-19 07:46:49 +02:00
parent d048b3940d
commit fc347599a5
1 changed files with 2 additions and 0 deletions

View File

@ -45,6 +45,8 @@ export default function Embed({ embed }: Props) {
return { width, height };
}
if(typeof embed.spoiler == 'undefined')
embed.spoiler = false;
switch (embed.type) {
case "Text":
case "Website": {