diff --git a/source/assets/javascripts/all.js b/source/assets/javascripts/all.js index bec14c6..e84aec9 100644 --- a/source/assets/javascripts/all.js +++ b/source/assets/javascripts/all.js @@ -21,7 +21,7 @@ document.addEventListener("DOMContentLoaded", function(){ paragraphs = []; paragraphs.push(lastParagraph); - while (lastParagraph.nextElementSibling.tagName == "P") { + while (lastParagraph.nextElementSibling && lastParagraph.nextElementSibling.tagName == "P") { lastParagraph = lastParagraph.nextElementSibling; paragraphs.push(lastParagraph) }