Skip to content

Commit

Permalink
Respect flag when resolving tagged definitions
Browse files Browse the repository at this point in the history
  • Loading branch information
philipobenito committed May 18, 2020
1 parent 1040b51 commit 93238f7
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@

All Notable changes to `League\Container` will be documented in this file

## 3.3.1

### Fixed
- Respect `$new` argument when getting tagged definitions.

## 3.3.0

### Added
Expand Down
2 changes: 1 addition & 1 deletion src/Container.php
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ public function get($id, bool $new = false)
}

if ($this->definitions->hasTag($id)) {
$arrayOf = $this->definitions->resolveTagged($id);
$arrayOf = $this->definitions->resolveTagged($id, $new);

array_walk($arrayOf, function (&$resolved) {
$resolved = $this->inflectors->inflect($resolved);
Expand Down

0 comments on commit 93238f7

Please sign in to comment.