Skip to content

Commit

Permalink
CHG: Removed dead code
Browse files Browse the repository at this point in the history
  • Loading branch information
gravataLonga committed Jun 7, 2022
1 parent b5df327 commit 9ed96ef
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
9 changes: 1 addition & 8 deletions src/Container.php
Expand Up @@ -350,14 +350,7 @@ private function resolve(string $id, array $arguments = [])
}

if ((!$this->has($id)) && (class_exists($id))) {
$get = $this->resolveClass($id, $arguments);

foreach ($this->getExtenders($id) as $extend) {
$get = $extend($this, $get);
$this->resolved[$id] = $get;
}

return $get;
return $this->resolveClass($id, $arguments);
}

if ($this->has($id)) {
Expand Down
1 change: 1 addition & 0 deletions tests/ExtendedMethodTest.php
Expand Up @@ -11,6 +11,7 @@
use ReflectionClass;
use Tests\Stub\AnimalInterface;
use Tests\Stub\Bar;
use Tests\Stub\Cat;
use Tests\Stub\Dog;
use Tests\Stub\FooInterface;
use TypeError;
Expand Down

0 comments on commit 9ed96ef

Please sign in to comment.