} else { $moveto = $fid; } $newforum = get_forum($moveto); if (!$newforum || $newforum['type'] != "f" || $newforum['type'] == "f" && $newforum['linkto'] != '') { error($lang->error_invalidforum); } // move the selected posts over $query = $db->simple_select("posts", "pid", "tid='{$tid}'"); while ($post = $db->fetch_array($query)) { if ($mybb->input['splitpost'][$post['pid']] == 1) { $pids[] = $post['pid']; } mark_reports($post['pid'], "post"); } $newtid = $moderation->split_posts($pids, $tid, $moveto, $mybb->input['newsubject']); log_moderator_action($modlogdata, $lang->thread_split); moderation_redirect(get_thread_link($newtid), $lang->redirect_threadsplit); break; // Delete Thread Subscriptions // Delete Thread Subscriptions case "removesubscriptions": if (!is_moderator($fid, "canmanagethreads")) { error_no_permission(); } $plugins->run_hooks("moderation_removesubscriptions"); $moderation->remove_thread_subscriptions($tid, true); log_moderator_action($modlogdata, $lang->removed_subscriptions); moderation_redirect(get_thread_link($thread['tid']), $lang->redirect_removed_subscriptions); break; // Delete Threads - Inline moderation
$moveto = $fid; } $newforum = get_forum($moveto); if (!$newforum || $newforum['type'] != "f" || $newforum['type'] == "f" && $newforum['linkto'] != '') { error($lang->error_invalidforum); } $pids = array(); // move the selected posts over $query = $db->simple_select("posts", "pid", "tid='{$tid}'"); while ($post = $db->fetch_array($query)) { if (isset($mybb->input['splitpost'][$post['pid']]) && $mybb->input['splitpost'][$post['pid']] == 1) { $pids[] = $post['pid']; } mark_reports($post['pid'], "post"); } $newtid = $moderation->split_posts($pids, $tid, $moveto, $mybb->get_input('newsubject')); log_moderator_action($modlogdata, $lang->thread_split); moderation_redirect(get_thread_link($newtid), $lang->redirect_threadsplit); break; // Delete Thread Subscriptions // Delete Thread Subscriptions case "removesubscriptions": if (!is_moderator($fid, "canmanagethreads")) { error_no_permission(); } $plugins->run_hooks("moderation_removesubscriptions"); $moderation->remove_thread_subscriptions($tid, true); log_moderator_action($modlogdata, $lang->removed_subscriptions); moderation_redirect(get_thread_link($thread['tid']), $lang->redirect_removed_subscriptions); break; // Delete Threads - Inline moderation