mirror of
https://github.com/streetwriters/notesnook.git
synced 2025-12-23 23:19:40 +01:00
core: fix Cannot read properties of undefined (reading 'length') error
This commit is contained in:
@@ -44,6 +44,7 @@ function wrapIntoHTMLDocument(input) {
|
||||
|
||||
export function extractFirstParagraph(html) {
|
||||
let text = "";
|
||||
try {
|
||||
let start = false;
|
||||
const parser = new Parser(
|
||||
{
|
||||
@@ -67,5 +68,6 @@ export function extractFirstParagraph(html) {
|
||||
}
|
||||
);
|
||||
parser.end(html);
|
||||
} catch (e) {}
|
||||
return text;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user