GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

Code Duplication    Length = 32-39 lines in 2 locations

phpmyfaq/src/phpMyFAQ/Permission/MediumPermission.php 2 locations

@@ 409-440 (lines=32) @@
406
     *
407
     * @return bool
408
     */
409
    public function isGroupMember($userId, $groupId)
410
    {
411
        if ($userId <= 0 || $groupId <= 0 || !is_numeric($userId) || !is_numeric($groupId)) {
412
            return false;
413
        }
414
415
        $select = sprintf('
416
            SELECT
417
                fu.user_id AS user_id
418
            FROM
419
                %sfaquser fu,
420
                %sfaquser_group fug,
421
                %sfaqgroup fg
422
            WHERE
423
                fu.user_id  = %d AND
424
                fu.user_id  = fug.user_id AND
425
                fg.group_id = fug.group_id AND
426
                fg.group_id = %d',
427
            Db::getTablePrefix(),
428
            Db::getTablePrefix(),
429
            Db::getTablePrefix(),
430
            $userId,
431
            $groupId
432
        );
433
434
        $res = $this->config->getDb()->query($select);
435
        if ($this->config->getDb()->numRows($res) == 1) {
436
            return true;
437
        }
438
439
        return false;
440
    }
441
442
    /**
443
     * Returns an array that contains the user-IDs of all members
@@ 736-774 (lines=39) @@
733
     *
734
     * @return bool
735
     */
736
    public function checkUserGroupRight($userId, $rightId)
737
    {
738
        // check input
739
        if ($rightId <= 0 || $userId <= 0 || !is_numeric($rightId) || !is_numeric($userId)) {
740
            return false;
741
        }
742
743
        $select = sprintf('
744
            SELECT
745
                fr.right_id AS right_id
746
            FROM
747
                %sfaqright fr,
748
                %sfaqgroup_right fgr,
749
                %sfaqgroup fg,
750
                %sfaquser_group fug,
751
                %sfaquser fu
752
            WHERE
753
                fr.right_id = %d AND
754
                fr.right_id = fgr.right_id AND
755
                fg.group_id = fgr.group_id AND
756
                fg.group_id = fug.group_id AND
757
                fu.user_id  = fug.user_id AND
758
                fu.user_id  = %d',
759
            Db::getTablePrefix(),
760
            Db::getTablePrefix(),
761
            Db::getTablePrefix(),
762
            Db::getTablePrefix(),
763
            Db::getTablePrefix(),
764
            $rightId,
765
            $userId
766
        );
767
768
        $res = $this->config->getDb()->query($select);
769
        if ($this->config->getDb()->numRows($res) == 1) {
770
            return true;
771
        }
772
773
        return false;
774
    }
775
776
    /**
777
     * Checks the given associative array $groupData. If a