recursively synchronizing subelements and subelements array