Passed
Pull Request — release-2.1 (#6274)
by Mathias
04:01
created
Sources/Load.php 2 patches
Braces   +1 added lines, -4 removed lines patch added patch discarded remove patch
@@ -104,7 +104,7 @@  discard block
 block discarded – undo
104 104
 	// Set a list of common functions.
105 105
 	$ent_list = '&(?:#' . (empty($modSettings['disableEntityCheck']) ? '\d{1,7}' : '021') . '|quot|amp|lt|gt|nbsp);';
106 106
 	$ent_check = empty($modSettings['disableEntityCheck']) ? function($string)
107
-		{
107
+	{
108 108
 			$string = preg_replace_callback('~(&#(\d{1,7}|x[0-9a-fA-F]{1,6});)~', 'entity_fix__callback', $string);
109 109
 			return $string;
110 110
 		} : function($string)
@@ -929,7 +929,6 @@  discard block
 block discarded – undo
929 929
 			$user_info_min[$row['id_member']]['time_offset'] = ($tz_user->getOffset($time_user) -
930 930
 					$tz_system->getOffset($time_system)) / 3600;
931 931
 		}
932
-
933 932
 		else
934 933
 			$user_info_min[$row['id_member']]['time_offset'] = empty($row['time_offset']) ? 0 : $row['time_offset'];
935 934
 	}
@@ -1657,7 +1656,6 @@  discard block
 block discarded – undo
1657 1656
 			$time_user = new DateTime('now', $tz_user);
1658 1657
 			$profile['time_offset'] = ($tz_user->getOffset($time_user) - $tz_system->getOffset($time_system)) / 3600;
1659 1658
 		}
1660
-
1661 1659
 		else
1662 1660
 		{
1663 1661
 			// !!! Compatibility.
@@ -2322,7 +2320,6 @@  discard block
 block discarded – undo
2322 2320
 		loadLanguage('index+Modifications');
2323 2321
 		$context['template_layers'] = array();
2324 2322
 	}
2325
-
2326 2323
 	else
2327 2324
 	{
2328 2325
 		// Custom templates to load, or just default?
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -800,7 +800,7 @@  discard block
 block discarded – undo
800 800
 			'filename' => empty($user_settings['filename']) ? '' : $user_settings['filename'],
801 801
 			'custom_dir' => !empty($user_settings['attachment_type']) && $user_settings['attachment_type'] == 1,
802 802
 			'id_attach' => isset($user_settings['id_attach']) ? $user_settings['id_attach'] : 0,
803
-			'width' => isset($user_settings['attachment_width']) > 0 ? $user_settings['attachment_width']: 0,
803
+			'width' => isset($user_settings['attachment_width']) > 0 ? $user_settings['attachment_width'] : 0,
804 804
 			'height' => isset($user_settings['attachment_height']) > 0 ? $user_settings['attachment_height'] : 0,
805 805
 		),
806 806
 		'smiley_set' => isset($user_settings['smiley_set']) ? $user_settings['smiley_set'] : '',
@@ -1741,7 +1741,7 @@  discard block
 block discarded – undo
1741 1741
 		if (!empty($image))
1742 1742
 			$memberContext[$user]['avatar'] = array(
1743 1743
 				'name' => $profile['avatar'],
1744
-				'image' => '<img class="avatar" src="' . $image . '" alt="" loading="lazy" width="' . $profile['attachment_width'] . 'px" height = "'. $profile['attachment_height'] . 'px">',
1744
+				'image' => '<img class="avatar" src="' . $image . '" alt="" loading="lazy" width="' . $profile['attachment_width'] . 'px" height = "' . $profile['attachment_height'] . 'px">',
1745 1745
 				'href' => $image,
1746 1746
 				'url' => $image,
1747 1747
 			);
Please login to merge, or discard this patch.
Themes/default/Profile.template.php 1 patch
Spacing   +2 added lines, -3 removed lines patch added patch discarded remove patch
@@ -1721,7 +1721,7 @@  discard block
 block discarded – undo
1721 1721
 		{
1722 1722
 			// Avoid double separators and empty titled sections
1723 1723
 			$empty_section = true;
1724
-			for ($j=$i+1; $j < count($context['theme_options']); $j++)
1724
+			for ($j = $i + 1; $j < count($context['theme_options']); $j++)
1725 1725
 			{
1726 1726
 				// Found another separator, so we're done
1727 1727
 				if (!is_array($context['theme_options'][$j]))
@@ -2700,8 +2700,7 @@  discard block
 block discarded – undo
2700 2700
 		foreach ($context['post_errors'] as $error)
2701 2701
 		{
2702 2702
 			$text_key_error = $error == 'password_short' ?
2703
-				sprintf($txt['profile_error_' . $error], (empty($modSettings['password_strength']) ? 4 : 8)) :
2704
-				$txt['profile_error_' . $error];
2703
+				sprintf($txt['profile_error_' . $error], (empty($modSettings['password_strength']) ? 4 : 8)) : $txt['profile_error_' . $error];
2705 2704
 
2706 2705
 			echo '
2707 2706
 				<li>', isset($txt['profile_error_' . $error]) ? $text_key_error : $error, '</li>';
Please login to merge, or discard this patch.