diff --git a/scripts/content.js b/scripts/content.js index 8241128..5445c3f 100644 --- a/scripts/content.js +++ b/scripts/content.js @@ -52,7 +52,7 @@ function checkNewMessages() { const el = messageNode.firstChild.firstChild.firstChild.firstChild; if (seenMessages.has(el)) continue; const rootNode = messageNode.parentNode.parentNode; - if (!rootNode.firstChild.firstChild) continue; + if (!rootNode?.firstChild?.firstChild) continue; const name = rootNode.firstChild.firstChild.innerHTML; newElements = true; seenMessages.add(el);