Fix judging issue

This commit is contained in:
patrick 2025-03-11 15:09:54 +00:00
parent 3e27d53758
commit 76b64e43c9
3 changed files with 3 additions and 5 deletions

View File

@ -85,8 +85,8 @@ function judge_status_questions($u)
*/
global $config, $pdo;
// get the questions we're looking for
$q = $pdo->prepare('SELECT id FROM questions WHERE year=? AND required=yes');
$q->execute([$config['FAIRYEAR']]);
$q = $pdo->prepare('SELECT id FROM questions WHERE year=? AND required=?');
$q->execute([$config['FAIRYEAR'], 'yes']);
$idList = array();
while ($row = $q->fetch(PDO::FETCH_ASSOC))
$idList[] = $row['id'];

View File

@ -557,8 +557,6 @@ function user_save(&$u)
show_pdo_errors_if_any($pdo);
}
echo '<pre>'; var_dump($u['password']); var_dump($u['orig']['password']); echo '</pre>';
/* Save the password if it changed */
if (($u['password'] == "") || ($u['password'] != $u['orig']['password']))
$u['password'] = user_set_password($u['id'], $u['password']);

View File

@ -369,7 +369,7 @@ if (in_array('committee', $u['types'])) {
echo '</table>';
}
echo '<input type="submit" onclick="personal_save()" value="' . i18n('Save Personal Information') . "\" />\n";
echo '<input type="submit" onclick="personal_save(); return false" value="' . i18n('Save Personal Information') . "\" />\n";
echo '</form>';