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 = 14-15 lines in 2 locations

install/migrations/2.2.0.php 1 location

@@ 55-68 (lines=14) @@
52
53
                $field_ids = array_merge($author, $checkbox, $date, $input, $textarea, $upload);
54
55
                foreach ($field_ids as $id) {
56
                    $table = '`tbl_entries_data_' . $id . '`';
57
58
                    try {
59
                        Symphony::Database()->query("ALTER TABLE " . $table . " DROP INDEX `entry_id`");
60
                    } catch (Exception $ex) {
61
                    }
62
63
                    try {
64
                        Symphony::Database()->query("CREATE UNIQUE INDEX `entry_id` ON " . $table . " (`entry_id`)");
65
                        Symphony::Database()->query("OPTIMIZE TABLE " . $table);
66
                    } catch (Exception $ex) {
67
                    }
68
                }
69
            }
70
71
            // Update the version information

install/migrations/2.3.0.php 1 location

@@ 132-146 (lines=15) @@
129
                // Refresh indexes on existing Author field tables
130
                $author_fields = Symphony::Database()->fetchCol("field_id", "SELECT `field_id` FROM `tbl_fields_author`");
131
132
                foreach ($author_fields as $id) {
133
                    $table = 'tbl_entries_data_' . $id;
134
135
                    // MySQL doesn't support DROP IF EXISTS, so we'll try and catch.
136
                    try {
137
                        Symphony::Database()->query("ALTER TABLE `" . $table . "` DROP INDEX `entry_id`");
138
                    } catch (Exception $ex) {
139
                    }
140
141
                    try {
142
                        Symphony::Database()->query("CREATE UNIQUE INDEX `author` ON `" . $table . "` (`entry_id`, `author_id`)");
143
                        Symphony::Database()->query("OPTIMIZE TABLE " . $table);
144
                    } catch (Exception $ex) {
145
                    }
146
                }
147
148
                // Move section sorting data from the database to the filesystem. #977
149
                if (Symphony::Database()->tableContainsField('tbl_sections', 'entry_order')) {