Details
Description
The problem is in the comment of function return value is Doctrine\ORM\Mapping\AssociationMapping.
My code expected to work with object of this type and normal situation is Fatal error: Call to a member function isOneToOne() on a non-object in /home/vis/projects/crm/trunk/library/Viscomp/Doctrine/Repository.php on line 371.
In my mind I suppose is normal to return object of Doctrine\ORM\Mapping\AssociationMapping, because in comment return value have this type.
I will be grateful if have fast answer because this is blocking issue for my project.
/**
* Gets the mapping of an association.
*
* @param string $fieldName The field name that represents the association in
* the object model.
* @return Doctrine\ORM\Mapping\AssociationMapping The mapping.
*/
public function getAssociationMapping($fieldName)
{
if ( ! isset($this->associationMappings[$fieldName])) {
throw MappingException::mappingNotFound($this->name, $fieldName);
}
return $this->associationMappings[$fieldName];
}