fix: added spoiler type check

This commit is contained in:
Skythrew
2022-09-19 07:46:49 +02:00
parent d048b3940d
commit fc347599a5

View File

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