eee
This commit is contained in:
+1
-1
@@ -165,7 +165,7 @@ class Container implements ContainerInterface
|
|||||||
throw new ReflectionException('Class ' . $className . ' cannot be instantiated');
|
throw new ReflectionException('Class ' . $className . ' cannot be instantiated');
|
||||||
}
|
}
|
||||||
|
|
||||||
if (($handler = $reflect->getConstructor()) !== null && empty($construct)) {
|
if (($handler = $reflect->getConstructor()) !== null) {
|
||||||
$construct = $this->getMethodParams($handler);
|
$construct = $this->getMethodParams($handler);
|
||||||
}
|
}
|
||||||
$newInstance = $reflect->newInstanceArgs($construct);
|
$newInstance = $reflect->newInstanceArgs($construct);
|
||||||
|
|||||||
+1
-2
@@ -98,8 +98,7 @@ class Scanner extends Component
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$object = $this->container->parse($class);
|
$object = $this->container->parse($class);
|
||||||
$methods = $this->container->getReflectionClass($class);
|
foreach ($reflect->getMethods(ReflectionMethod::IS_PUBLIC) as $method) {
|
||||||
foreach ($methods->getMethods(ReflectionMethod::IS_PUBLIC) as $method) {
|
|
||||||
if ($method->isStatic() || $method->getDeclaringClass()->getName() != $class) {
|
if ($method->isStatic() || $method->getDeclaringClass()->getName() != $class) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user