Code Duplication    Length = 2-2 lines in 5 locations

Sources/Profile-View.php 2 locations

@@ 487-488 (lines=2) @@
484
	$context['page_title'] .= ' - ' . $user_profile[$memID]['real_name'];
485
486
	// Is the load average too high to allow searching just now?
487
	if (!empty($context['load_average']) && !empty($modSettings['loadavg_show_posts']) && $context['load_average'] >= $modSettings['loadavg_show_posts'])
488
		fatal_lang_error('loadavg_show_posts_disabled', false);
489
490
	// If we're specifically dealing with attachments use that function!
491
	if (isset($_GET['sa']) && $_GET['sa'] == 'attach')
@@ 1243-1244 (lines=2) @@
1240
	$context['page_title'] = $txt['statPanel_showStats'] . ' ' . $user_profile[$memID]['real_name'];
1241
1242
	// Is the load average too high to allow searching just now?
1243
	if (!empty($context['load_average']) && !empty($modSettings['loadavg_userstats']) && $context['load_average'] >= $modSettings['loadavg_userstats'])
1244
		fatal_lang_error('loadavg_userstats_disabled', false);
1245
1246
	// General user statistics.
1247
	$timeDays = floor($user_profile[$memID]['total_time_logged_in'] / 86400);

Sources/Search.php 2 locations

@@ 42-43 (lines=2) @@
39
	global $txt, $scripturl, $modSettings, $user_info, $context, $smcFunc, $sourcedir;
40
41
	// Is the load average too high to allow searching just now?
42
	if (!empty($context['load_average']) && !empty($modSettings['loadavg_search']) && $context['load_average'] >= $modSettings['loadavg_search'])
43
		fatal_lang_error('loadavg_search_disabled', false);
44
45
	loadLanguage('Search');
46
	// Don't load this in XML mode.
@@ 262-263 (lines=2) @@
259
	if (isset($_REQUEST['search_selection']) && $_REQUEST['search_selection'] === 'members')
260
		redirectexit($scripturl . '?action=mlist;sa=search;fields=name,email;search=' . urlencode($_REQUEST['search']));
261
262
	if (!empty($context['load_average']) && !empty($modSettings['loadavg_search']) && $context['load_average'] >= $modSettings['loadavg_search'])
263
		fatal_lang_error('loadavg_search_disabled', false);
264
265
	// No, no, no... this is a bit hard on the server, so don't you go prefetching it!
266
	if (isset($_SERVER['HTTP_X_MOZ']) && $_SERVER['HTTP_X_MOZ'] == 'prefetch')

Sources/PersonalMessage.php 1 location

@@ 1197-1198 (lines=2) @@
1194
	global $scripturl, $modSettings, $user_info, $context, $txt;
1195
	global $memberContext, $smcFunc;
1196
1197
	if (!empty($context['load_average']) && !empty($modSettings['loadavg_search']) && $context['load_average'] >= $modSettings['loadavg_search'])
1198
		fatal_lang_error('loadavg_search_disabled', false);
1199
1200
	/**
1201
	 * @todo For the moment force the folder to the inbox.