refactored to use DeepDup instance for iteration
fixed many to one associations