fixed the object creation duplication