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 = 21-23 lines in 2 locations

phpmyfaq/inc/PMF/Faq.php 1 location

@@ 2813-2833 (lines=21) @@
2810
     *
2811
     * @author  Thorsten Rinne <[email protected]>
2812
     */
2813
    public function deletePermission($mode, $record_id)
2814
    {
2815
        if (!($mode == 'user' || $mode == 'group')) {
2816
            return false;
2817
        }
2818
        if (!is_int($record_id)) {
2819
            return false;
2820
        }
2821
2822
        $query = sprintf('
2823
            DELETE FROM
2824
                %sfaqdata_%s
2825
            WHERE
2826
                record_id = %d',
2827
            PMF_Db::getTablePrefix(),
2828
            $mode,
2829
            $record_id);
2830
        $this->_config->getDb()->query($query);
2831
2832
        return true;
2833
    }
2834
2835
    /**
2836
     * Returns the record permissions for users and groups.

phpmyfaq/inc/PMF/Category.php 1 location

@@ 1551-1573 (lines=23) @@
1548
     *
1549
     * @return bool
1550
     */
1551
    public function deletePermission($mode, $categories)
1552
    {
1553
        if (!($mode == 'user' || $mode == 'group')) {
1554
            return false;
1555
        }
1556
        if (!is_array($categories)) {
1557
            return false;
1558
        }
1559
1560
        foreach ($categories as $category_id) {
1561
            $query = sprintf('
1562
                DELETE FROM
1563
                    %sfaqcategory_%s
1564
                WHERE
1565
                    category_id = %d',
1566
                PMF_Db::getTablePrefix(),
1567
                $mode,
1568
                $category_id);
1569
            $this->_config->getDb()->query($query);
1570
        }
1571
1572
        return true;
1573
    }
1574
1575
    /**
1576
     * Returns the category permissions for users and groups.