Code Duplication    Length = 8-8 lines in 2 locations

src/Generators/AbstractGenerator.php 2 locations

@@ 168-175 (lines=8) @@
165
    {
166
        // @group tag on the method overrides that on the controller
167
        $docBlockComment = $method->getDocComment();
168
        if ($docBlockComment) {
169
            $phpdoc = new DocBlock($docBlockComment);
170
            foreach ($phpdoc->getTags() as $tag) {
171
                if ($tag->getName() === 'group') {
172
                    return $tag->getContent();
173
                }
174
            }
175
        }
176
177
        $docBlockComment = $controller->getDocComment();
178
        if ($docBlockComment) {
@@ 178-185 (lines=8) @@
175
        }
176
177
        $docBlockComment = $controller->getDocComment();
178
        if ($docBlockComment) {
179
            $phpdoc = new DocBlock($docBlockComment);
180
            foreach ($phpdoc->getTags() as $tag) {
181
                if ($tag->getName() === 'group') {
182
                    return $tag->getContent();
183
                }
184
            }
185
        }
186
187
        return 'general';
188
    }