Passed
Push — release-2.1 ( 4379ee...697d1f )
by John
07:32 queued 03:06
created
Sources/Load.php 1 patch
Spacing   +7 added lines, -10 removed lines patch added patch discarded remove patch
@@ -814,7 +814,7 @@  discard block
 block discarded – undo
814 814
 			'filename' => empty($user_settings['filename']) ? '' : $user_settings['filename'],
815 815
 			'custom_dir' => !empty($user_settings['attachment_type']) && $user_settings['attachment_type'] == 1,
816 816
 			'id_attach' => isset($user_settings['id_attach']) ? $user_settings['id_attach'] : 0,
817
-			'width' => isset($user_settings['attachment_width']) > 0 ? $user_settings['attachment_width']: 0,
817
+			'width' => isset($user_settings['attachment_width']) > 0 ? $user_settings['attachment_width'] : 0,
818 818
 			'height' => isset($user_settings['attachment_height']) > 0 ? $user_settings['attachment_height'] : 0,
819 819
 		),
820 820
 		'smiley_set' => isset($user_settings['smiley_set']) ? $user_settings['smiley_set'] : '',
@@ -2471,7 +2471,7 @@  discard block
 block discarded – undo
2471 2471
 	);
2472 2472
 
2473 2473
 	// Add the JQuery library to the list of files to load.
2474
-	$jQueryUrls = array ('cdn' => 'https://ajax.googleapis.com/ajax/libs/jquery/'. JQUERY_VERSION . '/jquery.min.js', 'jquery_cdn' => 'https://code.jquery.com/jquery-'. JQUERY_VERSION . '.min.js', 'microsoft_cdn' => 'https://ajax.aspnetcdn.com/ajax/jQuery/jquery-'. JQUERY_VERSION . '.min.js');
2474
+	$jQueryUrls = array('cdn' => 'https://ajax.googleapis.com/ajax/libs/jquery/' . JQUERY_VERSION . '/jquery.min.js', 'jquery_cdn' => 'https://code.jquery.com/jquery-' . JQUERY_VERSION . '.min.js', 'microsoft_cdn' => 'https://ajax.aspnetcdn.com/ajax/jQuery/jquery-' . JQUERY_VERSION . '.min.js');
2475 2475
 	
2476 2476
 	if (isset($modSettings['jquery_source']) && array_key_exists($modSettings['jquery_source'], $jQueryUrls))
2477 2477
 		loadJavaScriptFile($jQueryUrls[$modSettings['jquery_source']], array('external' => true, 'seed' => false), 'smf_jquery');
@@ -2712,8 +2712,7 @@  discard block
 block discarded – undo
2712 2712
 		$context['css_files_order'] = array();
2713 2713
 
2714 2714
 	$params['seed'] = (!array_key_exists('seed', $params) || (array_key_exists('seed', $params) && $params['seed'] === true)) ?
2715
-		(array_key_exists('browser_cache', $context) ? $context['browser_cache'] : '') :
2716
-		(is_string($params['seed']) ? '?' . ltrim($params['seed'], '?') : '');
2715
+		(array_key_exists('browser_cache', $context) ? $context['browser_cache'] : '') : (is_string($params['seed']) ? '?' . ltrim($params['seed'], '?') : '');
2717 2716
 	$params['force_current'] = isset($params['force_current']) ? $params['force_current'] : false;
2718 2717
 	$themeRef = !empty($params['default_theme']) ? 'default_theme' : 'theme';
2719 2718
 	$params['minimize'] = isset($params['minimize']) ? $params['minimize'] : true;
@@ -2828,8 +2827,7 @@  discard block
 block discarded – undo
2828 2827
 	global $settings, $context, $modSettings;
2829 2828
 
2830 2829
 	$params['seed'] = (!array_key_exists('seed', $params) || (array_key_exists('seed', $params) && $params['seed'] === true)) ?
2831
-		(array_key_exists('browser_cache', $context) ? $context['browser_cache'] : '') :
2832
-		(is_string($params['seed']) ? '?' . ltrim($params['seed'], '?') : '');
2830
+		(array_key_exists('browser_cache', $context) ? $context['browser_cache'] : '') : (is_string($params['seed']) ? '?' . ltrim($params['seed'], '?') : '');
2833 2831
 	$params['force_current'] = isset($params['force_current']) ? $params['force_current'] : false;
2834 2832
 	$themeRef = !empty($params['default_theme']) ? 'default_theme' : 'theme';
2835 2833
 	$params['async'] = isset($params['async']) ? $params['async'] : false;
@@ -2934,7 +2932,7 @@  discard block
 block discarded – undo
2934 2932
 					$elements[] = JavaScriptEscape($element);
2935 2933
 			}
2936 2934
 
2937
-			$value = '[' . implode(', ',$elements) . ']';
2935
+			$value = '[' . implode(', ', $elements) . ']';
2938 2936
 		}
2939 2937
 	}
2940 2938
 
@@ -3615,8 +3613,7 @@  discard block
 block discarded – undo
3615 3613
 
3616 3614
 	// What accelerator we are going to try.
3617 3615
 	$cache_class_name = !empty($cache_accelerator) ? $cache_accelerator : CacheApi::APIS_DEFAULT;
3618
-	$fully_qualified_class_name = !empty($overrideCache) ? $overrideCache :
3619
-		CacheApi::APIS_NAMESPACE . $cache_class_name;
3616
+	$fully_qualified_class_name = !empty($overrideCache) ? $overrideCache : CacheApi::APIS_NAMESPACE . $cache_class_name;
3620 3617
 
3621 3618
 	// Do some basic tests.
3622 3619
 	if (class_exists($fully_qualified_class_name))
@@ -3920,7 +3917,7 @@  discard block
 block discarded – undo
3920 3917
 			$auth_secret = hash_file('sha256', $boarddir . '/Settings.php');
3921 3918
 
3922 3919
 			// Set the last error to now, but only every 15 minutes.  Don't need to flood the logs.
3923
-			if (empty($db_last_error) || ($db_last_error + 60*15) <= time())
3920
+			if (empty($db_last_error) || ($db_last_error + 60 * 15) <= time())
3924 3921
 			{
3925 3922
 				updateDbLastError(time());
3926 3923
 				loadLanguage('Errors');
Please login to merge, or discard this patch.
Sources/Register.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -315,7 +315,7 @@
 block discarded – undo
315 315
 
316 316
 	array_walk_recursive(
317 317
 		$_POST,
318
-		function (&$value, $key) use ($context, $smcFunc)
318
+		function(&$value, $key) use ($context, $smcFunc)
319 319
 		{
320 320
 			// Replace any kind of space with a normal space, and remove any kind of control character, then trim.
321 321
 			$value = $smcFunc['htmltrim'](preg_replace(array('~[\h\v]+~' . ($context['utf8'] ? 'u' : ''), '~\p{Cc}+~'), array(' ', ''), $value));
Please login to merge, or discard this patch.