| @@ -40,9 +40,9 @@ discard block | ||
| 40 | 40 | * @param mixed $value | 
| 41 | 41 | * @return self | 
| 42 | 42 | */ | 
| 43 | - public function to(string|array|callable $value): Bindings | |
| 43 | + public function to(string | array | callable $value): Bindings | |
| 44 | 44 |      { | 
| 45 | -        if(isset($this->bindings[$this->activeKey])) { | |
| 45 | +        if (isset($this->bindings[$this->activeKey])) { | |
| 46 | 46 | $this->bindings[$this->activeKey]['binding'] = $value; | 
| 47 | 47 |          } else { | 
| 48 | 48 | $this->bindings[$this->activeKey] = ['binding' => $value, 'calls' => [], 'properties' => []]; | 
| @@ -59,7 +59,7 @@ discard block | ||
| 59 | 59 | public function get(string $key): array | 
| 60 | 60 |      { | 
| 61 | 61 | $binding = $this->bindings[$key]; | 
| 62 | -        if(!isset($binding['binding'])) { | |
| 62 | +        if (!isset($binding['binding'])) { | |
| 63 | 63 | $binding['binding'] = $key; | 
| 64 | 64 | } | 
| 65 | 65 | return $binding; | 
| @@ -93,7 +93,7 @@ discard block | ||
| 93 | 93 | */ | 
| 94 | 94 | private function setArrayBinding(array $binding): void | 
| 95 | 95 |      { | 
| 96 | -        if(isset($binding[0])) { | |
| 96 | +        if (isset($binding[0])) { | |
| 97 | 97 | $this->to($binding[0]); | 
| 98 | 98 | } | 
| 99 | 99 | |
| @@ -107,9 +107,9 @@ discard block | ||
| 107 | 107 | */ | 
| 108 | 108 | public function merge(array $bindings): void | 
| 109 | 109 |      { | 
| 110 | -        foreach($bindings as $key => $binding) { | |
| 110 | +        foreach ($bindings as $key => $binding) { | |
| 111 | 111 | $this->activeKey = $key; | 
| 112 | -            if(is_array($binding)) { | |
| 112 | +            if (is_array($binding)) { | |
| 113 | 113 | $this->setArrayBinding($binding); | 
| 114 | 114 |              } else { | 
| 115 | 115 | $this->bindings[$key] = ['binding' => $binding, 'calls' => [], 'properties' => []]; | 
| @@ -123,7 +123,7 @@ discard block | ||
| 123 | 123 | return $this; | 
| 124 | 124 | } | 
| 125 | 125 | |
| 126 | - public function with(string|array|callable $value): Bindings | |
| 126 | + public function with(string | array | callable $value): Bindings | |
| 127 | 127 |      { | 
| 128 | 128 | return $this->to($value); | 
| 129 | 129 | } | 
| @@ -179,8 +179,8 @@ discard block | ||
| 179 | 179 | private function injectAttributed(mixed $instance, \ReflectionClass $reflection): void | 
| 180 | 180 |      { | 
| 181 | 181 | // Properties | 
| 182 | -        foreach($reflection->getProperties() as $property) { | |
| 183 | -            if (count($property->getAttributes(Inject::class)) == 0 ) { | |
| 182 | +        foreach ($reflection->getProperties() as $property) { | |
| 183 | +            if (count($property->getAttributes(Inject::class)) == 0) { | |
| 184 | 184 | continue; | 
| 185 | 185 | } | 
| 186 | 186 | $type = $property->getType(); | 
| @@ -196,7 +196,7 @@ discard block | ||
| 196 | 196 | } | 
| 197 | 197 | |
| 198 | 198 | // Methods | 
| 199 | -        foreach($reflection->getMethods() as $method) { | |
| 199 | +        foreach ($reflection->getMethods() as $method) { | |
| 200 | 200 |              if (count($method->getAttributes(Inject::class)) == 0) { | 
| 201 | 201 | continue; | 
| 202 | 202 | } | 
| @@ -212,7 +212,7 @@ discard block | ||
| 212 | 212 | * @return mixed | 
| 213 | 213 | * @throws exceptions\ResolutionException | 
| 214 | 214 | */ | 
| 215 | - private function getInstance(string|callable $class): mixed | |
| 215 | + private function getInstance(string | callable $class): mixed | |
| 216 | 216 |      { | 
| 217 | 217 | // If the class is a function call it as a factory. | 
| 218 | 218 |          if (is_callable($class)) { |