Split the hasChildren check in domMemberProvider.addMember into a separate function
Some DOM-tree code cleanup
Use the right hasChildren in watch and DOM providers