@@ -38,9 +38,9 @@ |
||
| 38 | 38 | public function createInjection(\ReflectionClass $class, string $context = null) |
| 39 | 39 | { |
| 40 | 40 | $schema = $this->orm->getSchema(); |
| 41 | - foreach ($schema->getRoles() as $role) { |
|
| 41 | + foreach ($schema->getRoles() as $role){ |
|
| 42 | 42 | $repository = $schema->define($role, Schema::REPOSITORY); |
| 43 | - if ($repository !== Select\Repository::class && $repository === $class->getName()) { |
|
| 43 | + if ($repository !== Select\Repository::class && $repository === $class->getName()){ |
|
| 44 | 44 | return $this->orm->getRepository($role); |
| 45 | 45 | } |
| 46 | 46 | } |
@@ -38,9 +38,11 @@ |
||
| 38 | 38 | public function createInjection(\ReflectionClass $class, string $context = null) |
| 39 | 39 | { |
| 40 | 40 | $schema = $this->orm->getSchema(); |
| 41 | - foreach ($schema->getRoles() as $role) { |
|
| 41 | + foreach ($schema->getRoles() as $role) |
|
| 42 | + { |
|
| 42 | 43 | $repository = $schema->define($role, Schema::REPOSITORY); |
| 43 | - if ($repository !== Select\Repository::class && $repository === $class->getName()) { |
|
| 44 | + if ($repository !== Select\Repository::class && $repository === $class->getName()) |
|
| 45 | + { |
|
| 44 | 46 | return $this->orm->getRepository($role); |
| 45 | 47 | } |
| 46 | 48 | } |