Correct the checks in step 5 of Node::pre_insert.
auto merge of #4003 : Ms2ger/servo/pre-insert, r=jdm