Class relatedGenericClass = MappingUtils.getGenericTypeForProperty(relatedClassType, descriptor.getName());
ManyToMany relatedManyToMany = getAnnotation(referencedCpf, descriptor, ManyToMany.class);
if (relatedGenericClass == null) {
relatedGenericClass = relatedManyToMany.targetEntity();
}
<BUG>if (relatedGenericClass == genericClass) {
</BUG>
if (relatedManyToMany != null && relatedManyToMany.mappedBy().equals(property.getName())) {
<BUG>entity.addOwner(relatedClassType);
break;</BUG>
}

Class relatedGenericClass = MappingUtils.getGenericTypeForProperty(relatedClassType, descriptor.getName());
ManyToMany relatedManyToMany = getAnnotation(referencedCpf, descriptor, ManyToMany.class);
if (relatedGenericClass == null) {
relatedGenericClass = relatedManyToMany.targetEntity();
