diff --git a/editor/base/JoinElementTxn.cpp b/editor/base/JoinElementTxn.cpp index ed076f1d533c..cee9303ebad2 100644 --- a/editor/base/JoinElementTxn.cpp +++ b/editor/base/JoinElementTxn.cpp @@ -140,7 +140,7 @@ NS_IMETHODIMP JoinElementTxn::Undo(void) if (NS_FAILED(result)) {return result;} if (!child) {return NS_ERROR_NULL_POINTER;} child->GetNextSibling(getter_AddRefs(nextSibling)); - result = mRightNode->RemoveChild(child, getter_AddRefs(resultNode)); + result = mLeftNode->AppendChild(child, getter_AddRefs(resultNode)); child = do_QueryInterface(nextSibling); } } diff --git a/editor/libeditor/base/JoinElementTxn.cpp b/editor/libeditor/base/JoinElementTxn.cpp index ed076f1d533c..cee9303ebad2 100644 --- a/editor/libeditor/base/JoinElementTxn.cpp +++ b/editor/libeditor/base/JoinElementTxn.cpp @@ -140,7 +140,7 @@ NS_IMETHODIMP JoinElementTxn::Undo(void) if (NS_FAILED(result)) {return result;} if (!child) {return NS_ERROR_NULL_POINTER;} child->GetNextSibling(getter_AddRefs(nextSibling)); - result = mRightNode->RemoveChild(child, getter_AddRefs(resultNode)); + result = mLeftNode->AppendChild(child, getter_AddRefs(resultNode)); child = do_QueryInterface(nextSibling); } }