Preserve argument order on insertion.
Fix some buginess in previous commit.