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

phpmyfaq/admin/group.php 1 location

@@ 152-192 (lines=41) @@
149
}
150
151
// delete group confirmation
152
if ($groupAction == 'delete_confirm' && $user->perm->checkRight($user->getUserId(), 'delgroup')) {
153
    $message = '';
154
    $user = new CurrentUser($faqConfig);
155
    $perm = $user->perm;
156
    $groupId = Filter::filterInput(INPUT_POST, 'group_list_select', FILTER_VALIDATE_INT, 0);
157
    if ($groupId <= 0) {
158
        $message    .= sprintf('<p class="alert alert-danger">%s</p>', $PMF_LANG['ad_user_error_noId']);
159
        $groupAction = $defaultGroupAction;
160
    } else {
161
        $groupData = $perm->getGroupData($groupId);
162
        ?>
163
        <header class="row">
164
            <div class="col-lg-12">
165
                <h2 class="page-header">
166
                    <i aria-hidden="true" class="fas fa-users fa-fw"></i>
167
                    <?= $PMF_LANG['ad_group_deleteGroup'] ?> "<?= $groupData['name'] ?>"
168
                </h2>
169
            </div>
170
        </header>
171
172
        <div class="row">
173
            <div class="col-lg-12">
174
                <p><?= $PMF_LANG['ad_group_deleteQuestion'] ?></p>
175
                <form action ="?action=group&amp;group_action=delete" method="post">
176
                    <input type="hidden" name="group_id" value="<?= $groupId ?>">
177
                    <input type="hidden" name="csrf" value="<?= $user->getCsrfTokenFromSession()?>">
178
                    <p>
179
                        <button class="btn btn-inverse" type="submit" name="cancel">
180
                            <?= $PMF_LANG['ad_gen_cancel'] ?>
181
                        </button>
182
                        <button class="btn btn-primary" type="submit">
183
                            <?= $PMF_LANG['ad_gen_save'] ?>
184
                        </button>
185
                    </p>
186
                </form>
187
            </div>
188
        </div>
189
<?php
190
191
    }
192
}
193
194
if ($groupAction == 'delete' && $user->perm->checkRight($user->getUserId(), 'delgroup')) {
195
    $message = '';

phpmyfaq/admin/section.php 1 location

@@ 126-166 (lines=41) @@
123
}
124
125
// delete section confirmation
126
if ($sectionAction == 'delete_confirm' && $user->perm->checkRight($user->getUserId(), 'delete_section')) {
127
    $message = '';
128
    $user = new CurrentUser($faqConfig);
129
    $perm = $user->perm;
130
    $sectionId = Filter::filterInput(INPUT_POST, 'section_list_select', FILTER_VALIDATE_INT, 0);
131
    if ($sectionId <= 0) {
132
        $message    .= sprintf('<p class="alert alert-danger">%s</p>', $PMF_LANG['ad_user_error_noId']);
133
        $sectionAction = $defaultSectionAction;
134
    } else {
135
        $sectionData = $perm->getSectionData($sectionId);
136
        ?>
137
      <header class="row">
138
          <div class="col-lg-12">
139
              <h2 class="page-header">
140
                  <i aria-hidden="true" class="fas fa-users fa-fw"></i>
141
                  <?= $PMF_LANG['ad_section_deleteSection'] ?> "<?= $sectionData['name'] ?>"
142
              </h2>
143
          </div>
144
      </header>
145
146
      <div class="row">
147
          <div class="col-lg-12">
148
              <p><?= $PMF_LANG['ad_section_deleteQuestion'] ?></p>
149
              <form action ="?action=section&amp;section_action=delete" method="post">
150
                  <input type="hidden" name="section_id" value="<?= $sectionId ?>">
151
                  <input type="hidden" name="csrf" value="<?= $user->getCsrfTokenFromSession()?>">
152
                  <p>
153
                      <button class="btn btn-inverse" type="submit" name="cancel">
154
                          <?= $PMF_LANG['ad_gen_cancel'] ?>
155
                      </button>
156
                      <button class="btn btn-primary" type="submit">
157
                          <?= $PMF_LANG['ad_gen_delete'] ?>
158
                      </button>
159
                  </p>
160
              </form>
161
          </div>
162
      </div>
163
<?php
164
165
    }
166
}
167
168
if ($sectionAction == 'delete' && $user->perm->checkRight($user->getUserId(), 'delete_section')) {
169
    $message = '';