1
0
mirror of synced 2025-01-18 06:21:40 +03:00

Oops, shouldn't have removed the condition completely... checking a parameter is provided

This commit is contained in:
Nadav 2011-08-26 07:51:29 +03:00
parent d314386060
commit 5fc6277d3f

View File

@ -204,6 +204,11 @@ class EntityRepository implements ObjectRepository
);
}
if (count($arguments) === 0) {
throw ORMException::findByRequiresParameter($method.$by);
}
$fieldName = lcfirst(\Doctrine\Common\Util\Inflector::classify($by));
if ($this->_class->hasField($fieldName) || $this->_class->hasAssociation($fieldName)) {