| Conditions | 2 |
| Paths | 2 |
| Total Lines | 11 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 6 |
| CRAP Score | 2 |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 26 | 2 | public function resolve(string $pluginAlias): object |
|
| 27 | { |
||
| 28 | 2 | if (\array_key_exists($pluginAlias, $this->cache)) { |
|
| 29 | 1 | return $this->cache[$pluginAlias]; |
|
| 30 | } |
||
| 31 | |||
| 32 | 2 | $result = $this->pluginClassResolver->resolve($pluginAlias); |
|
| 33 | |||
| 34 | 2 | $this->cache[$pluginAlias] = $result; |
|
| 35 | |||
| 36 | 2 | return $result; |
|
| 37 | } |
||
| 39 |