small bugfixes

This commit is contained in:
Michael Save 2012-05-19 20:52:45 +10:00
parent 93c3ceb04d
commit d2c6853ed3

View File

@ -175,11 +175,6 @@ function mod_edit_board($boardName) {
$query->bindValue(':uri', $board['uri'], PDO::PARAM_INT);
$query->execute() or error(db_error($query));
if ($config['cache']['enabled']) {
cache::delete('board_' . $board['uri']);
cache::delete('all_boards');
}
$query = prepare("SELECT `board`, `post` FROM `cites` WHERE `target_board` = :board");
$query->bindValue(':board', $board['uri']);
$query->execute() or error(db_error($query));
@ -207,6 +202,11 @@ function mod_edit_board($boardName) {
$query->execute() or error(db_error($query));
}
if ($config['cache']['enabled']) {
cache::delete('board_' . $board['uri']);
cache::delete('all_boards');
}
rebuildThemes('boards');
header('Location: ?/', true, $config['redirect_http']);
@ -1189,7 +1189,7 @@ function mod_user_new() {
$query->bindValue(':boards', implode(',', $boards));
$query->execute() or error(db_error($query));
$uid = $pdo->lastInsertId();
$userID = $pdo->lastInsertId();
modLog('Created a new user: ' . utf8tohtml($_POST['username']) . ' <small>(#' . $userID . ')</small>');