diff options
Diffstat (limited to 'Libraries')
-rw-r--r-- | Libraries/LibWeb/TreeNode.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Libraries/LibWeb/TreeNode.h b/Libraries/LibWeb/TreeNode.h index 3cd4742137..96e8155b61 100644 --- a/Libraries/LibWeb/TreeNode.h +++ b/Libraries/LibWeb/TreeNode.h @@ -380,6 +380,8 @@ inline void TreeNode<T>::insert_before(NonnullRefPtr<T> node, RefPtr<T> child, b node->m_previous_sibling = child->m_previous_sibling; node->m_next_sibling = child; + child->m_previous_sibling = node; + if (m_first_child == child) m_first_child = node; |