Browse Source

Fixes two bugs preventing replies from being moved.

pull/68/head
jove 7 years ago
parent
commit
8e0a8b1251
1 changed files with 3 additions and 2 deletions
  1. +3
    -2
      inc/mod/pages.php

+ 3
- 2
inc/mod/pages.php View File

@@ -1140,8 +1140,9 @@ function mod_move_reply($originBoard, $postID) {

// build index
buildIndex();

// build new thread
buildThread($newID);
buildThread($post['op'] ? $newID : $post['thread']);
// trigger themes
rebuildThemes('post', $targetBoard);
@@ -1159,7 +1160,7 @@ function mod_move_reply($originBoard, $postID) {
openBoard($targetBoard);

// Find new thread on our target board
$query = prepare(sprintf('SELECT thread FROM ``posts_%s`` WHERE `id` = :id', $targetBoard));
$query = prepare(sprintf('SELECT thread, id FROM ``posts_%s`` WHERE `id` = :id', $targetBoard));
$query->bindValue(':id', $newID);
$query->execute() or error(db_error($query));
$post = $query->fetch(PDO::FETCH_ASSOC);


Loading…
Cancel
Save