Code Duplication    Length = 9-9 lines in 2 locations

src/AppBundle/Controller/ArticleInfoController.php 2 locations

@@ 480-488 (lines=9) @@
477
478
        $errors = [];
479
480
        if (!in_array('label', $terms)) {
481
            $errors[] = [
482
                'prio' => 2,
483
                'name' => 'Wikidata',
484
                'notice' => "Label for language <em>$lang</em> is missing", // FIXME: i18n
485
                'explanation' => "See: <a target='_blank' " .
486
                    "href='//www.wikidata.org/wiki/Help:Label'>Help:Label</a>",
487
            ];
488
        }
489
        if (!in_array('description', $terms)) {
490
            $errors[] = [
491
                'prio' => 3,
@@ 489-497 (lines=9) @@
486
                    "href='//www.wikidata.org/wiki/Help:Label'>Help:Label</a>",
487
            ];
488
        }
489
        if (!in_array('description', $terms)) {
490
            $errors[] = [
491
                'prio' => 3,
492
                'name' => 'Wikidata',
493
                'notice' => "Description for language <em>$lang</em> is missing", // FIXME: i18n
494
                'explanation' => "See: <a target='_blank' " .
495
                    "href='//www.wikidata.org/wiki/Help:Description'>Help:Description</a>",
496
            ];
497
        }
498
499
        return $errors;
500
    }