MODE-2375 Fixed the logic of processing references after XML import: the reference properties should only be set at the end of the import, after all the nodes have been added to their respective parents - i.e. the nodes graph is fully created.  This is because when setting reference properties the referrer calculation(s) are performed.
Merge pull request #1331 from hchiorean/MODE-2375

MODE-2375 Fixed the logic of processing references after XML import