Issue #3379148 by bgreco, s_leu, Rajeshreeputra: Referenced files are cloned twice. Cloned parent entity references the wrong file