cardSchema: take innerHTML instead, force type to 'link' if html is empty

environments/review-card-sanit-co7mzr/deployments/4447
Alex Gleason 2024-03-14 19:09:00 -05:00
rodzic d53c1c2227
commit 8633eca37d
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 7211D1F99744FBB7
1 zmienionych plików z 5 dodań i 1 usunięć

Wyświetl plik

@ -76,7 +76,11 @@ const cardSchema = z.object({
}
});
card.html = html.outerHTML;
card.html = html.innerHTML;
if (!card.html) {
card.type = 'link';
}
return card;
});