only check for traits when class exists
This commit is contained in:
parent
8e3e2e770a
commit
8898c91dfc
@ -710,6 +710,7 @@ public function __construct()
|
|||||||
}
|
}
|
||||||
|
|
||||||
// check traits for existing property
|
// check traits for existing property
|
||||||
|
if (class_exists($metadata->name)) {
|
||||||
$reflClass = new \ReflectionClass($metadata->name);
|
$reflClass = new \ReflectionClass($metadata->name);
|
||||||
|
|
||||||
foreach ($reflClass->getTraits() as $trait) {
|
foreach ($reflClass->getTraits() as $trait) {
|
||||||
@ -717,6 +718,7 @@ public function __construct()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
isset($this->staticReflection[$metadata->name]) &&
|
isset($this->staticReflection[$metadata->name]) &&
|
||||||
@ -742,6 +744,7 @@ public function __construct()
|
|||||||
}
|
}
|
||||||
|
|
||||||
// check traits for existing method
|
// check traits for existing method
|
||||||
|
if (class_exists($metadata->name)) {
|
||||||
$reflClass = new \ReflectionClass($metadata->name);
|
$reflClass = new \ReflectionClass($metadata->name);
|
||||||
|
|
||||||
foreach ($reflClass->getTraits() as $trait) {
|
foreach ($reflClass->getTraits() as $trait) {
|
||||||
@ -749,6 +752,7 @@ public function __construct()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
isset($this->staticReflection[$metadata->name]) &&
|
isset($this->staticReflection[$metadata->name]) &&
|
||||||
|
Loading…
x
Reference in New Issue
Block a user