Code Duplication    Length = 8-8 lines in 2 locations

src/Tools/Generator.php 2 locations

@@ 353-360 (lines=8) @@
350
    {
351
        // @group tag on the method overrides that on the controller
352
        $docBlockComment = $method->getDocComment();
353
        if ($docBlockComment) {
354
            $phpdoc = new DocBlock($docBlockComment);
355
            foreach ($phpdoc->getTags() as $tag) {
356
                if ($tag->getName() === 'group') {
357
                    return $tag->getContent();
358
                }
359
            }
360
        }
361
362
        $docBlockComment = $controller->getDocComment();
363
        if ($docBlockComment) {
@@ 363-370 (lines=8) @@
360
        }
361
362
        $docBlockComment = $controller->getDocComment();
363
        if ($docBlockComment) {
364
            $phpdoc = new DocBlock($docBlockComment);
365
            foreach ($phpdoc->getTags() as $tag) {
366
                if ($tag->getName() === 'group') {
367
                    return $tag->getContent();
368
                }
369
            }
370
        }
371
372
        return $this->config->get(('default_group'));
373
    }