Code Duplication    Length = 5-5 lines in 2 locations

src/Plugin/Annotation.php 2 locations

@@ 168-172 (lines=5) @@
165
            $reflection = new ReflectionClass($class);
166
            $className = $reflection->getShortName();
167
168
            if ($reflection->isSubclassOf(Repository::class)) {
169
                if ($this->repositoryPostifx) {
170
                    $className = substr($className, 0, strlen($className) - strlen($this->repositoryPostifx));
171
                }
172
            }
173
174
            if ($reflection->isSubclassOf(Entity::class)) {
175
                if ($this->entityPostfix) {
@@ 174-178 (lines=5) @@
171
                }
172
            }
173
174
            if ($reflection->isSubclassOf(Entity::class)) {
175
                if ($this->entityPostfix) {
176
                    $className = substr($className, 0, strlen($className) - strlen($this->entityPostfix));
177
                }
178
            }
179
180
            $this->spaceNames[$class] = $this->toUnderscore($className);
181
        }