Vergleich moderation.php - 1.8.34 - 1.8.38

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 39Zeile 39
$fid = $mybb->get_input('fid', MyBB::INPUT_INT);
$pmid = $mybb->get_input('pmid', MyBB::INPUT_INT);
$modal = $mybb->get_input('modal', MyBB::INPUT_INT);

$fid = $mybb->get_input('fid', MyBB::INPUT_INT);
$pmid = $mybb->get_input('pmid', MyBB::INPUT_INT);
$modal = $mybb->get_input('modal', MyBB::INPUT_INT);

 

if($mybb->user['uid'] == 0)
{
error_no_permission();
}



if($pid)
{
$post = get_post($pid);
if(!$post)


if($pid)
{
$post = get_post($pid);
if(!$post)

	{

	{

		error($lang->error_invalidpost, $lang->error);
}
$tid = $post['tid'];

		error($lang->error_invalidpost, $lang->error);
}
$tid = $post['tid'];

}

}


if($tid)
{


if($tid)
{

Zeile 75Zeile 81
if($pmid > 0)
{
$query = $db->simple_select('privatemessages', 'uid, subject, ipaddress, fromid', "pmid = $pmid");

if($pmid > 0)
{
$query = $db->simple_select('privatemessages', 'uid, subject, ipaddress, fromid', "pmid = $pmid");





	$pm = $db->fetch_array($query);

if(!$pm)

	$pm = $db->fetch_array($query);

if(!$pm)

Zeile 142Zeile 148
{
// Delayed Moderation
case "cancel_delayedmoderation":

{
// Delayed Moderation
case "cancel_delayedmoderation":

		// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

add_breadcrumb($lang->delayed_moderation);
if(!is_moderator($fid, "canmanagethreads"))

		// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

add_breadcrumb($lang->delayed_moderation);
if(!is_moderator($fid, "canmanagethreads"))

		{
error_no_permission();

		{
error_no_permission();

		}

$plugins->run_hooks('moderation_cancel_delayedmoderation');

		}

$plugins->run_hooks('moderation_cancel_delayedmoderation');


$db->delete_query("delayedmoderation", "did='".$mybb->get_input('did', MyBB::INPUT_INT)."'");



$db->delete_query("delayedmoderation", "did='".$mybb->get_input('did', MyBB::INPUT_INT)."'");


Zeile 160Zeile 166
			moderation_redirect(get_forum_link($fid), $lang->redirect_delayed_moderation_cancelled);
}
else

			moderation_redirect(get_forum_link($fid), $lang->redirect_delayed_moderation_cancelled);
}
else

		{

		{

			moderation_redirect("moderation.php?action=delayedmoderation&tid={$tid}&my_post_key={$mybb->post_code}", $lang->redirect_delayed_moderation_cancelled);
}
break;

			moderation_redirect("moderation.php?action=delayedmoderation&tid={$tid}&my_post_key={$mybb->post_code}", $lang->redirect_delayed_moderation_cancelled);
}
break;

Zeile 182Zeile 188

// Assume in-line moderation if TID is not set
if(!empty($mybb->input['tid']))


// Assume in-line moderation if TID is not set
if(!empty($mybb->input['tid']))

		{

		{

			$mybb->input['tids'] = $tid;
}
else

			$mybb->input['tids'] = $tid;
}
else

Zeile 253Zeile 259
					break;
default:
$query = $db->simple_select("modtools", 'tid, name, `groups`', "(CONCAT(',',forums,',') LIKE '%,$fid,%' OR CONCAT(',',forums,',') LIKE '%,-1,%' OR forums='') AND type = 't'");

					break;
default:
$query = $db->simple_select("modtools", 'tid, name, `groups`', "(CONCAT(',',forums,',') LIKE '%,$fid,%' OR CONCAT(',',forums,',') LIKE '%,-1,%' OR forums='') AND type = 't'");

			}

			}

			while($tool = $db->fetch_array($query))
{
if(is_member($tool['groups']))

			while($tool = $db->fetch_array($query))
{
if(is_member($tool['groups']))

Zeile 324Zeile 330
			}

if($mybb->input['date_year'] < gmdate('Y', TIME_NOW + $localized_time_offset))

			}

if($mybb->input['date_year'] < gmdate('Y', TIME_NOW + $localized_time_offset))

			{

			{

				$errors[] = $lang->error_delayedmoderation_invalid_date_year;
}


				$errors[] = $lang->error_delayedmoderation_invalid_date_year;
}


Zeile 360Zeile 366
				));

$plugins->run_hooks('moderation_do_delayedmoderation');

				));

$plugins->run_hooks('moderation_do_delayedmoderation');





				$rundate_format = my_date('relative', $rundate, '', 2);
$lang->redirect_delayed_moderation_thread = $lang->sprintf($lang->redirect_delayed_moderation_thread, $rundate_format);


				$rundate_format = my_date('relative', $rundate, '', 2);
$lang->redirect_delayed_moderation_thread = $lang->sprintf($lang->redirect_delayed_moderation_thread, $rundate_format);


Zeile 429Zeile 435
		if(isset($errors) && count($errors) > 0)
{
$display_errors = inline_error($errors);

		if(isset($errors) && count($errors) > 0)
{
$display_errors = inline_error($errors);

		}
else
{

		}
else
{

			$display_errors = '';
}


			$display_errors = '';
}


Zeile 503Zeile 509
				ORDER BY d.dateline DESC
LIMIT 0, 20
");

				ORDER BY d.dateline DESC
LIMIT 0, 20
");

		}

		}

		else
{
switch($db->type)

		else
{
switch($db->type)

Zeile 609Zeile 615
		else
{
if($mybb->get_input('inlinetype') == 'search')

		else
{
if($mybb->get_input('inlinetype') == 'search')

			{

			{

				$tids = getids($mybb->get_input('searchid'), 'search');
$url = htmlspecialchars_uni($mybb->get_input('url'));
}

				$tids = getids($mybb->get_input('searchid'), 'search');
$url = htmlspecialchars_uni($mybb->get_input('url'));
}

Zeile 1014Zeile 1020

$plugins->run_hooks("moderation_move");



$plugins->run_hooks("moderation_move");


		$forumselect = build_forum_jump("", '', 1, '', 0, true, '', "moveto");

		$forumselect = build_forum_jump("", $fid, 1, '', 0, true, '', "moveto");

		eval("\$movethread = \"".$templates->get("moderation_move")."\";");
output_page($movethread);
break;

		eval("\$movethread = \"".$templates->get("moderation_move")."\";");
output_page($movethread);
break;

Zeile 1748Zeile 1754
		}
mark_reports($tlist, "threads");
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsdeleted);

		}
mark_reports($tlist, "threads");
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsdeleted);

		break;


		break;


	// Open threads - Inline moderation
case "multiopenthreads":

	// Open threads - Inline moderation
case "multiopenthreads":


// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

if(!empty($mybb->input['searchid']))
{
// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canopenclosethreads'))
{
error_no_permission();
}
}
else
{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canopenclosethreads'))
{
error_no_permission();
}
}

if(count($threads) < 1)
{
error($lang->error_inline_nothreadsselected, $lang->error);
}

$moderation->open_threads($threads);



// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

if(!empty($mybb->input['searchid']))
{
// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canopenclosethreads'))
{
error_no_permission();
}
}
else
{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canopenclosethreads'))
{
error_no_permission();
}
}

if(count($threads) < 1)
{
error($lang->error_inline_nothreadsselected, $lang->error);
}

$moderation->open_threads($threads);


		log_moderator_action($modlogdata, $lang->multi_opened_threads);
if($mybb->get_input('inlinetype') == 'search')
{

		log_moderator_action($modlogdata, $lang->multi_opened_threads);
if($mybb->get_input('inlinetype') == 'search')
{

Zeile 1792Zeile 1798
		}
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsopened);
break;

		}
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsopened);
break;





	// Close threads - Inline moderation
case "multiclosethreads":


	// Close threads - Inline moderation
case "multiclosethreads":


Zeile 1800Zeile 1806
		verify_post_check($mybb->get_input('my_post_key'));

if(!empty($mybb->input['searchid']))

		verify_post_check($mybb->get_input('my_post_key'));

if(!empty($mybb->input['searchid']))

		{

		{

			// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canopenclosethreads'))

			// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canopenclosethreads'))

Zeile 1812Zeile 1818
		{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canopenclosethreads'))

		{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canopenclosethreads'))

			{

			{

				error_no_permission();
}
}
if(count($threads) < 1)

				error_no_permission();
}
}
if(count($threads) < 1)

		{

		{

			error($lang->error_inline_nothreadsselected, $lang->error);

			error($lang->error_inline_nothreadsselected, $lang->error);

		}


		}


		$moderation->close_threads($threads);

log_moderator_action($modlogdata, $lang->multi_closed_threads);

		$moderation->close_threads($threads);

log_moderator_action($modlogdata, $lang->multi_closed_threads);

Zeile 1829Zeile 1835
			clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');
}
else

			clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');
}
else

		{

		{

			clearinline($fid, 'forum');
}
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsclosed);
break;

// Approve threads - Inline moderation

			clearinline($fid, 'forum');
}
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsclosed);
break;

// Approve threads - Inline moderation

	case "multiapprovethreads":

// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

if(!empty($mybb->input['searchid']))
{
// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canapproveunapprovethreads'))
{
error_no_permission();
}
}

	case "multiapprovethreads":

// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

if(!empty($mybb->input['searchid']))
{
// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canapproveunapprovethreads'))
{
error_no_permission();
}
}

		else
{
$threads = getids($fid, 'forum');

		else
{
$threads = getids($fid, 'forum');

Zeile 1857Zeile 1863
			{
error_no_permission();
}

			{
error_no_permission();
}

		}

		}

		if(count($threads) < 1)
{
error($lang->error_inline_nothreadsselected, $lang->error);

		if(count($threads) < 1)
{
error($lang->error_inline_nothreadsselected, $lang->error);

		}

		}


$moderation->approve_threads($threads, $fid);



$moderation->approve_threads($threads, $fid);


Zeile 1869Zeile 1875
		if($mybb->get_input('inlinetype') == 'search')
{
clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');

		if($mybb->get_input('inlinetype') == 'search')
{
clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');

		}

		}

		else
{
clearinline($fid, 'forum');
}
$cache->update_stats();
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsapproved);

		else
{
clearinline($fid, 'forum');
}
$cache->update_stats();
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsapproved);

		break;


		break;


	// Unapprove threads - Inline moderation
case "multiunapprovethreads":

	// Unapprove threads - Inline moderation
case "multiunapprovethreads":





		// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));


		// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));


Zeile 1889Zeile 1895
			// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canapproveunapprovethreads'))

			// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canapproveunapprovethreads'))

			{
error_no_permission();
}
}

			{
error_no_permission();
}
}

		else
{
$threads = getids($fid, 'forum');

		else
{
$threads = getids($fid, 'forum');

Zeile 1900Zeile 1906
			{
error_no_permission();
}

			{
error_no_permission();
}

		}

		}

		if(count($threads) < 1)
{
error($lang->error_inline_nothreadsselected, $lang->error);

		if(count($threads) < 1)
{
error($lang->error_inline_nothreadsselected, $lang->error);

Zeile 1909Zeile 1915
		$moderation->unapprove_threads($threads, $fid);

log_moderator_action($modlogdata, $lang->multi_unapproved_threads);

		$moderation->unapprove_threads($threads, $fid);

log_moderator_action($modlogdata, $lang->multi_unapproved_threads);

		if($mybb->get_input('inlinetype') == 'search')
{

		if($mybb->get_input('inlinetype') == 'search')
{

			clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');

			clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');

		}

		}

		else
{
clearinline($fid, 'forum');

		else
{
clearinline($fid, 'forum');

		}

		}

		$cache->update_stats();
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsunapproved);
break;

		$cache->update_stats();
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsunapproved);
break;





	// Restore threads - Inline moderation
case "multirestorethreads":


	// Restore threads - Inline moderation
case "multirestorethreads":


Zeile 1928Zeile 1934
		verify_post_check($mybb->get_input('my_post_key'));

if(!empty($mybb->input['searchid']))

		verify_post_check($mybb->get_input('my_post_key'));

if(!empty($mybb->input['searchid']))

		{

		{

			// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canrestorethreads'))

			// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canrestorethreads'))

			{

			{

				error_no_permission();
}
}

				error_no_permission();
}
}

Zeile 1940Zeile 1946
		{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canrestorethreads'))

		{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canrestorethreads'))

			{
error_no_permission();
}
}
if(count($threads) < 1)
{
error($lang->error_inline_nothreadsselected, $lang->error);
}

$moderation->restore_threads($threads);

log_moderator_action($modlogdata, $lang->multi_restored_threads);
if($mybb->get_input('inlinetype') == 'search')
{
clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');
}
else
{
clearinline($fid, 'forum');
}
$cache->update_stats();
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsrestored);
break;

// Soft delete threads - Inline moderation
case "multisoftdeletethreads":

// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

if(!empty($mybb->input['searchid']))
{
// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'cansoftdeletethreads'))
{
error_no_permission();
}
}
else
{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'cansoftdeletethreads'))
{
error_no_permission();
}

			{
error_no_permission();
}












































		}
if(count($threads) < 1)
{
error($lang->error_inline_nothreadsselected, $lang->error);

		}
if(count($threads) < 1)
{
error($lang->error_inline_nothreadsselected, $lang->error);

		}

$moderation->soft_delete_threads($threads);

log_moderator_action($modlogdata, $lang->multi_soft_deleted_threads);

		}

$moderation->restore_threads($threads);

log_moderator_action($modlogdata, $lang->multi_restored_threads);

		if($mybb->get_input('inlinetype') == 'search')
{
clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');

		if($mybb->get_input('inlinetype') == 'search')
{
clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');

		}

		}

		else
{
clearinline($fid, 'forum');
}
$cache->update_stats();

		else
{
clearinline($fid, 'forum');
}
$cache->update_stats();

		moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadssoftdeleted);

		moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsrestored);

		break;

		break;


// Stick threads - Inline moderation
case "multistickthreads":


// Soft delete threads - Inline moderation
case "multisoftdeletethreads":


// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));


// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

Zeile 2017Zeile 1980
		{
// From search page
$threads = getids($mybb->get_input('searchid'), 'search');

		{
// From search page
$threads = getids($mybb->get_input('searchid'), 'search');

			if(!is_moderator_by_tids($threads, 'canstickunstickthreads'))
{
error_no_permission();
}
}
else
{

			if(!is_moderator_by_tids($threads, 'cansoftdeletethreads'))
{
error_no_permission();
}
}
else
{

			$threads = getids($fid, 'forum');

			$threads = getids($fid, 'forum');

			if(!is_moderator($fid, 'canstickunstickthreads'))

			if(!is_moderator($fid, 'cansoftdeletethreads'))

			{
error_no_permission();
}

			{
error_no_permission();
}

		}

		}

		if(count($threads) < 1)

		if(count($threads) < 1)

		{












































		{
error($lang->error_inline_nothreadsselected, $lang->error);
}

$moderation->soft_delete_threads($threads);

log_moderator_action($modlogdata, $lang->multi_soft_deleted_threads);
if($mybb->get_input('inlinetype') == 'search')
{
clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');
}
else
{
clearinline($fid, 'forum');
}
$cache->update_stats();
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadssoftdeleted);
break;

// Stick threads - Inline moderation
case "multistickthreads":

// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

if(!empty($mybb->input['searchid']))
{
// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canstickunstickthreads'))
{
error_no_permission();
}
}
else
{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canstickunstickthreads'))
{
error_no_permission();
}
}
if(count($threads) < 1)
{

			error($lang->error_inline_nothreadsselected, $lang->error);
}


			error($lang->error_inline_nothreadsselected, $lang->error);
}


Zeile 2041Zeile 2047
		if($mybb->get_input('inlinetype') == 'search')
{
clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');

		if($mybb->get_input('inlinetype') == 'search')
{
clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');

		}
else

		}
else

		{
clearinline($fid, 'forum');
}

		{
clearinline($fid, 'forum');
}

Zeile 2051Zeile 2057

// Unstick threads - Inline moderaton
case "multiunstickthreads":


// Unstick threads - Inline moderaton
case "multiunstickthreads":





		// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

if(!empty($mybb->input['searchid']))

		// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

if(!empty($mybb->input['searchid']))

		{

		{

			// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canstickunstickthreads'))

			// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canstickunstickthreads'))

Zeile 2068Zeile 2074
		{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canstickunstickthreads'))

		{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canstickunstickthreads'))

			{
error_no_permission();
}
}

			{
error_no_permission();
}
}

		if(count($threads) < 1)

		if(count($threads) < 1)

		{
error($lang->error_inline_nothreadsselected, $lang->error);
}

		{
error($lang->error_inline_nothreadsselected, $lang->error);
}


$moderation->unstick_threads($threads);



$moderation->unstick_threads($threads);


Zeile 2083Zeile 2089
		if($mybb->get_input('inlinetype') == 'search')
{
clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');

		if($mybb->get_input('inlinetype') == 'search')
{
clearinline($mybb->get_input('searchid', MyBB::INPUT_INT), 'search');

		}

		}

		else
{
clearinline($fid, 'forum');

		else
{
clearinline($fid, 'forum');

		}

		}

		moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsunstuck);
break;


		moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsunstuck);
break;


Zeile 2100Zeile 2106
			// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canmanagethreads'))

			// From search page
$threads = getids($mybb->get_input('searchid'), 'search');
if(!is_moderator_by_tids($threads, 'canmanagethreads'))

			{
error_no_permission();
}
}
else

			{
error_no_permission();
}
}
else

		{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canmanagethreads'))

		{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canmanagethreads'))

Zeile 2131Zeile 2137
		eval("\$movethread = \"".$templates->get("moderation_inline_movethreads")."\";");
output_page($movethread);
break;

		eval("\$movethread = \"".$templates->get("moderation_inline_movethreads")."\";");
output_page($movethread);
break;





	// Actually move the threads in Inline moderation
case "do_multimovethreads":


	// Actually move the threads in Inline moderation
case "do_multimovethreads":


Zeile 2139Zeile 2145
		verify_post_check($mybb->get_input('my_post_key'));

$moveto = $mybb->get_input('moveto', MyBB::INPUT_INT);

		verify_post_check($mybb->get_input('my_post_key'));

$moveto = $mybb->get_input('moveto', MyBB::INPUT_INT);

		$method = $mybb->get_input('method');


		$method = $mybb->get_input('method');


		$threadlist = explode("|", $mybb->get_input('threads'));
if(!is_moderator_by_tids($threadlist, 'canmanagethreads'))
{
error_no_permission();

		$threadlist = explode("|", $mybb->get_input('threads'));
if(!is_moderator_by_tids($threadlist, 'canmanagethreads'))
{
error_no_permission();

		}

		}

		foreach($threadlist as $tid)
{
$tids[] = (int)$tid;

		foreach($threadlist as $tid)
{
$tids[] = (int)$tid;

		}

		}

		// Make sure moderator has permission to move to the new forum
$newperms = forum_permissions($moveto);
if(($newperms['canview'] == 0 || !is_moderator($moveto, 'canmanagethreads')) && !is_moderator_by_tids($tids, 'canmovetononmodforum'))

		// Make sure moderator has permission to move to the new forum
$newperms = forum_permissions($moveto);
if(($newperms['canview'] == 0 || !is_moderator($moveto, 'canmanagethreads')) && !is_moderator_by_tids($tids, 'canmovetononmodforum'))

Zeile 2161Zeile 2167
		if(!$newforum || $newforum['type'] != "f" || $newforum['type'] == "f" && $newforum['linkto'] != '')
{
error($lang->error_invalidforum, $lang->error);

		if(!$newforum || $newforum['type'] != "f" || $newforum['type'] == "f" && $newforum['linkto'] != '')
{
error($lang->error_invalidforum, $lang->error);

		}


		}


		$plugins->run_hooks('moderation_do_multimovethreads');

log_moderator_action($modlogdata, $lang->multi_moved_threads);

		$plugins->run_hooks('moderation_do_multimovethreads');

log_moderator_action($modlogdata, $lang->multi_moved_threads);

Zeile 2174Zeile 2180

foreach($tids as $tid) {
$moderation->move_thread($tid, $moveto, $method, $expire);


foreach($tids as $tid) {
$moderation->move_thread($tid, $moveto, $method, $expire);

		}


		}


		moderation_redirect(get_forum_link($moveto), $lang->redirect_inline_threadsmoved);
break;

		moderation_redirect(get_forum_link($moveto), $lang->redirect_inline_threadsmoved);
break;





	// Delete posts - Inline moderation
case "multideleteposts":
add_breadcrumb($lang->nav_multi_deleteposts);

	// Delete posts - Inline moderation
case "multideleteposts":
add_breadcrumb($lang->nav_multi_deleteposts);





		if($mybb->get_input('inlinetype') == 'search')
{
$posts = getids($mybb->get_input('searchid'), 'search');

		if($mybb->get_input('inlinetype') == 'search')
{
$posts = getids($mybb->get_input('searchid'), 'search');

		}

		}

		else
{
$posts = getids($tid, 'thread');

		else
{
$posts = getids($tid, 'thread');

		}

		}


if(count($posts) < 1)
{
error($lang->error_inline_nopostsselected, $lang->error);


if(count($posts) < 1)
{
error($lang->error_inline_nopostsselected, $lang->error);

		}

		}

		if(!is_moderator_by_pids($posts, "candeleteposts"))
{
error_no_permission();

		if(!is_moderator_by_pids($posts, "candeleteposts"))
{
error_no_permission();

		}

		}

		$inlineids = implode("|", $posts);
if($mybb->get_input('inlinetype') == 'search')
{

		$inlineids = implode("|", $posts);
if($mybb->get_input('inlinetype') == 'search')
{

Zeile 2208Zeile 2214
		else
{
clearinline($tid, 'thread');

		else
{
clearinline($tid, 'thread');

		}

$return_url = htmlspecialchars_uni($mybb->get_input('url'));


		}

$return_url = htmlspecialchars_uni($mybb->get_input('url'));


		eval("\$multidelete = \"".$templates->get("moderation_inline_deleteposts")."\";");
output_page($multidelete);
break;

		eval("\$multidelete = \"".$templates->get("moderation_inline_deleteposts")."\";");
output_page($multidelete);
break;

Zeile 2315Zeile 2321
			}
}


			}
}


		if(empty($posts))

		if(count($posts) < 2)

		{

		{

			error($lang->error_inline_nopostsselected, $lang->error);





			if(empty($posts))
{
error($lang->error_inline_nopostsselected, $lang->error);
}
error($lang->error_nomergeposts, $lang->error);

		}

if(!is_moderator_by_pids($posts, "canmanagethreads"))

		}

if(!is_moderator_by_pids($posts, "canmanagethreads"))

Zeile 2379Zeile 2389
		verify_post_check($mybb->get_input('my_post_key'));

$mergepost = $mybb->get_input('mergepost', MyBB::INPUT_ARRAY);

		verify_post_check($mybb->get_input('my_post_key'));

$mergepost = $mybb->get_input('mergepost', MyBB::INPUT_ARRAY);

		if(count($mergepost) <= 1)

		if(count($mergepost) < 2)

		{
error($lang->error_nomergeposts, $lang->error);
}

		{
error($lang->error_nomergeposts, $lang->error);
}

Zeile 3016Zeile 3026

$uid = $mybb->get_input('uid', MyBB::INPUT_INT);
$user = get_user($uid);


$uid = $mybb->get_input('uid', MyBB::INPUT_INT);
$user = get_user($uid);

		if(!$user['uid'] || !purgespammer_show($user['postnum'], $user['usergroup'], $user['uid']))

		if(!$user || !purgespammer_show($user['postnum'], $user['usergroup'], $user['uid']))

		{
error($lang->purgespammer_invalid_user);
}

		{
error($lang->purgespammer_invalid_user);
}