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 = 12-19 lines in 7 locations

phpmyfaq/inc/PMF/Faq.php 5 locations

@@ 1079-1094 (lines=16) @@
1076
     * @param  string  $record_lang Language
1077
     * @return boolean
1078
     */
1079
    public function deleteCategoryRelations($record_id, $record_lang)
1080
    {
1081
        $query = sprintf("
1082
            DELETE FROM
1083
                %sfaqcategoryrelations
1084
            WHERE
1085
                record_id = %d
1086
            AND
1087
                record_lang = '%s'",
1088
            PMF_Db::getTablePrefix(),
1089
            $record_id,
1090
            $record_lang);
1091
        $this->_config->getDb()->query($query);
1092
1093
        return true;
1094
    }
1095
1096
    /**
1097
     * Returns an array with all data from a FAQ record
@@ 1452-1470 (lines=19) @@
1449
     * @param  string  $record_lang Record language
1450
     * @return array
1451
     */
1452
    public function addNewRevision($record_id, $record_lang)
1453
    {
1454
        $query = sprintf("
1455
            INSERT INTO
1456
                %sfaqdata_revisions
1457
            SELECT * FROM
1458
                %sfaqdata
1459
            WHERE
1460
                id = %d
1461
            AND
1462
                lang = '%s'",
1463
            PMF_Db::getTablePrefix(),
1464
            PMF_Db::getTablePrefix(),
1465
            $record_id,
1466
            $record_lang);
1467
        $this->_config->getDb()->query($query);
1468
1469
        return true;
1470
    }
1471
1472
1473
    /**
@@ 1659-1672 (lines=14) @@
1656
     *
1657
     * @return boolean
1658
     */
1659
    function deleteQuestion($questionId)
1660
    {
1661
        $delete = sprintf('
1662
            DELETE FROM
1663
                %sfaqquestions
1664
            WHERE
1665
                id = %d',
1666
            PMF_Db::getTablePrefix(),
1667
            $questionId
1668
        );
1669
1670
        $this->_config->getDb()->query($delete);
1671
        return true;
1672
    }
1673
1674
    /**
1675
     * Returns the visibilty of a question
@@ 1713-1728 (lines=16) @@
1710
     * @since   2006-11-04
1711
     * @author  Thorsten Rinne <[email protected]>
1712
     */
1713
    function setVisibilityOfQuestion($question_id, $is_visible)
1714
    {
1715
        $query = sprintf("
1716
            UPDATE
1717
                %sfaqquestions
1718
            SET
1719
                is_visible = '%s'
1720
            WHERE
1721
                id = %d",
1722
            PMF_Db::getTablePrefix(),
1723
            $is_visible,
1724
            $question_id);
1725
        
1726
        $this->_config->getDb()->query($query);
1727
        return true;
1728
    }
1729
1730
    /**
1731
     * This function generates a data-set with the mosted voted recors
@@ 3039-3050 (lines=12) @@
3036
     *
3037
     * @return boolean
3038
     */
3039
    public function updateQuestionAnswer($openQuestionId, $faqId, $categoryId)
3040
    {
3041
        $query = sprintf(
3042
            'UPDATE %sfaqquestions SET answer_id = %d, category_id= %d, WHERE id= %d',
3043
            PMF_Db::getTablePrefix(),
3044
            $faqId,
3045
            $categoryId,
3046
            $openQuestionId
3047
        );
3048
3049
        return $this->_config->getDb()->query($query);
3050
    }
3051
3052
    /**
3053
     * Returns a part of a query to check permissions

phpmyfaq/inc/PMF/Logging.php 1 location

@@ 59-72 (lines=14) @@
56
     *
57
     * @return integer
58
     */
59
    public function getNumberOfEntries()
60
    {
61
        $query = sprintf('
62
            SELECT
63
                id
64
            FROM
65
                %sfaqadminlog',
66
            PMF_Db::getTablePrefix()
67
        );
68
69
        return $this->_config->getDb()->numRows(
70
            $this->_config->getDb()->query($query)
71
        );
72
    }
73
74
    /**
75
     * Returns all data from the adminlog

phpmyfaq/inc/PMF/Session.php 1 location

@@ 256-272 (lines=17) @@
253
     *
254
     * @return boolean
255
     */
256
    public function deleteSessions($first, $last)
257
    {
258
        $query = sprintf("
259
            DELETE FROM
260
                %sfaqsessions
261
            WHERE
262
                time >= %d
263
            AND
264
                time <= %d",
265
            PMF_Db::getTablePrefix(),
266
            $first,
267
            $last);
268
269
        $this->_config->getDb()->query($query);
270
271
        return true;
272
    }
273
274
    /**
275
     * Checks the Session ID