@@ -15,17 +15,17 @@ |
||
| 15 | 15 | { |
| 16 | 16 | public static function resolve( |
| 17 | 17 | string $alias, |
| 18 | - \Stringable|string|null $context = null, |
|
| 18 | + \Stringable | string | null $context = null, |
|
| 19 | 19 | ?ContainerInterface $c = null |
| 20 | 20 | ): object { |
| 21 | 21 | $c ??= ContainerScope::getContainer() ?? throw new ContainerException('Proxy is out of scope.'); |
| 22 | 22 | |
| 23 | - try { |
|
| 23 | + try{ |
|
| 24 | 24 | /** @psalm-suppress TooManyArguments */ |
| 25 | 25 | $result = $c->get($alias, $context) ?? throw new ContainerException( |
| 26 | 26 | 'Resolved `null` from the container.', |
| 27 | 27 | ); |
| 28 | - } catch (\Throwable $e) { |
|
| 28 | + }catch (\Throwable $e){ |
|
| 29 | 29 | throw new ContainerException( |
| 30 | 30 | \sprintf('Unable to resolve `%s` in a Proxy.', $alias), |
| 31 | 31 | previous: $e, |
@@ -20,12 +20,15 @@ |
||
| 20 | 20 | ): object { |
| 21 | 21 | $c ??= ContainerScope::getContainer() ?? throw new ContainerException('Proxy is out of scope.'); |
| 22 | 22 | |
| 23 | - try { |
|
| 23 | + try |
|
| 24 | + { |
|
| 24 | 25 | /** @psalm-suppress TooManyArguments */ |
| 25 | 26 | $result = $c->get($alias, $context) ?? throw new ContainerException( |
| 26 | 27 | 'Resolved `null` from the container.', |
| 27 | 28 | ); |
| 28 | - } catch (\Throwable $e) { |
|
| 29 | + } |
|
| 30 | + catch (\Throwable $e) |
|
| 31 | + { |
|
| 29 | 32 | throw new ContainerException( |
| 30 | 33 | \sprintf('Unable to resolve `%s` in a Proxy.', $alias), |
| 31 | 34 | previous: $e, |