diff --git a/Userland/Libraries/LibWeb/Layout/LineBox.cpp b/Userland/Libraries/LibWeb/Layout/LineBox.cpp index 894344fe5c..de4d900ad4 100644 --- a/Userland/Libraries/LibWeb/Layout/LineBox.cpp +++ b/Userland/Libraries/LibWeb/Layout/LineBox.cpp @@ -61,6 +61,8 @@ bool LineBox::is_empty_or_ends_in_whitespace() const { if (m_fragments.is_empty()) return true; + if (m_fragments.last().length() == 0) + return true; return m_fragments.last().ends_in_whitespace(); }