Commit b140ea71 authored by romanb's avatar romanb

improved _isDoctrineEntity check

parent 90047298
...@@ -64,13 +64,6 @@ class Doctrine_Query_Parser_AbstractSchemaName extends Doctrine_Query_ParserRule ...@@ -64,13 +64,6 @@ class Doctrine_Query_Parser_AbstractSchemaName extends Doctrine_Query_ParserRule
protected function _isDoctrineEntity($componentName) protected function _isDoctrineEntity($componentName)
{ {
if (class_exists($componentName)) { return class_exists($componentName) && is_subclass_of($componentName, 'Doctrine_ORM_Entity');
$reflectionClass = new ReflectionClass($componentName);
$dctrnEntityReflectionClass = new ReflectionClass('Doctrine_ORM_Entity');
return $reflectionClass->isSubclassOf($dctrnEntityReflectionClass);
}
return false;
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment