Passed
Pull Request — release-2.1 (#6088)
by Mathias
03:43
created
other/install.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -959,7 +959,7 @@
 block discarded – undo
959 959
 	$incontext['continue'] = 1;
960 960
 
961 961
 	// Check Postgres setting
962
-	if ( $db_type === 'postgresql')
962
+	if ($db_type === 'postgresql')
963 963
 	{
964 964
 		load_database();
965 965
 		$result = $smcFunc['db_query']('', '
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -973,7 +973,7 @@
 block discarded – undo
973 973
 		{
974 974
 			$row = $smcFunc['db_fetch_assoc']($result);
975 975
 			if ($row['standard_conforming_strings'] !== 'on')
976
-				{
976
+			{
977 977
 					$incontext['continue'] = 0;
978 978
 					$incontext['error'] = $txt['error_pg_scs'];
979 979
 				}
Please login to merge, or discard this patch.
Sources/Display.php 1 patch
Spacing   +17 added lines, -17 removed lines patch added patch discarded remove patch
@@ -1631,14 +1631,14 @@  discard block
 block discarded – undo
1631 1631
 	$output['quickbuttons'] = array(
1632 1632
 		'quote' => array(
1633 1633
 			'label' => $txt['quote_action'],
1634
-			'href' => $scripturl.'?action=post;quote='.$output['id'].';topic='.$context['current_topic'], '.'.$context['start'].';last_msg='.$context['topic_last_message'],
1635
-			'javascript' => 'onclick="return oQuickReply.quote('.$output['id'].');"',
1634
+			'href' => $scripturl . '?action=post;quote=' . $output['id'] . ';topic=' . $context['current_topic'], '.' . $context['start'] . ';last_msg=' . $context['topic_last_message'],
1635
+			'javascript' => 'onclick="return oQuickReply.quote(' . $output['id'] . ');"',
1636 1636
 			'icon' => 'quote',
1637 1637
 			'show' => $context['can_quote']
1638 1638
 		),
1639 1639
 		'quote_selected' => array(
1640 1640
 			'label' => $txt['quote_selected_action'],
1641
-			'id' => 'quoteSelected_'. $output['id'],
1641
+			'id' => 'quoteSelected_' . $output['id'],
1642 1642
 			'href' => 'javascript:void(0)',
1643 1643
 			'custom' => 'style="display:none"',
1644 1644
 			'icon' => 'quote_selected',
@@ -1647,71 +1647,71 @@  discard block
 block discarded – undo
1647 1647
 		'quick_edit' => array(
1648 1648
 			'label' => $txt['quick_edit'],
1649 1649
 			'class' => 'quick_edit',
1650
-			'id' =>' modify_button_'. $output['id'],
1651
-			'custom' => 'onclick="oQuickModify.modifyMsg(\''.$output['id'].'\', \''.!empty($modSettings['toggle_subject']).'\')"',
1650
+			'id' =>' modify_button_' . $output['id'],
1651
+			'custom' => 'onclick="oQuickModify.modifyMsg(\'' . $output['id'] . '\', \'' . !empty($modSettings['toggle_subject']) . '\')"',
1652 1652
 			'icon' => 'quick_edit_button',
1653 1653
 			'show' => $output['can_modify']
1654 1654
 		),
1655 1655
 		'more' => array(
1656 1656
 			'modify' => array(
1657 1657
 				'label' => $txt['modify'],
1658
-				'href' => $scripturl.'?action=post;msg='.$output['id'].';topic='.$context['current_topic'].'.'.$context['start'],
1658
+				'href' => $scripturl . '?action=post;msg=' . $output['id'] . ';topic=' . $context['current_topic'] . '.' . $context['start'],
1659 1659
 				'icon' => 'modify_button',
1660 1660
 				'show' => $output['can_modify']
1661 1661
 			),
1662 1662
 			'remove_topic' => array(
1663 1663
 				'label' => $txt['remove_topic'],
1664
-				'href' => $scripturl.'?action=removetopic2;topic='.$context['current_topic'].'.'.$context['start'].';'.$context['session_var'].'='.$context['session_id'],
1665
-				'javascript' => 'data-confirm="'.$txt['are_sure_remove_topic'].'" class="you_sure"',
1664
+				'href' => $scripturl . '?action=removetopic2;topic=' . $context['current_topic'] . '.' . $context['start'] . ';' . $context['session_var'] . '=' . $context['session_id'],
1665
+				'javascript' => 'data-confirm="' . $txt['are_sure_remove_topic'] . '" class="you_sure"',
1666 1666
 				'icon' => 'remove_button',
1667 1667
 				'show' => $context['can_delete'] && ($context['topic_first_message'] == $output['id'])
1668 1668
 			),
1669 1669
 			'remove' => array(
1670 1670
 				'label' => $txt['remove'],
1671
-				'href' => $scripturl.'?action=deletemsg;topic='.$context['current_topic'].'.'.$context['start'].';msg='.$output['id'].';'.$context['session_var'].'='.$context['session_id'],
1672
-				'javascript' => 'data-confirm="'.$txt['remove_message_question'].'" class="you_sure"',
1671
+				'href' => $scripturl . '?action=deletemsg;topic=' . $context['current_topic'] . '.' . $context['start'] . ';msg=' . $output['id'] . ';' . $context['session_var'] . '=' . $context['session_id'],
1672
+				'javascript' => 'data-confirm="' . $txt['remove_message_question'] . '" class="you_sure"',
1673 1673
 				'icon' => 'remove_button',
1674 1674
 				'show' => $output['can_remove'] && ($context['topic_first_message'] != $output['id'])
1675 1675
 			),
1676 1676
 			'split' => array(
1677 1677
 				'label' => $txt['split'],
1678
-				'href' => $scripturl.'?action=splittopics;topic='.$context['current_topic'].'.0;at='.$output['id'],
1678
+				'href' => $scripturl . '?action=splittopics;topic=' . $context['current_topic'] . '.0;at=' . $output['id'],
1679 1679
 				'icon' => 'split_button',
1680 1680
 				'show' => $context['can_split'] && !empty($context['real_num_replies'])
1681 1681
 			),
1682 1682
 			'report' => array(
1683 1683
 				'label' => $txt['report_to_mod'],
1684
-				'href' => $scripturl.'?action=reporttm;topic='.$context['current_topic'].'.'.$output['counter'].';msg='.$output['id'],
1684
+				'href' => $scripturl . '?action=reporttm;topic=' . $context['current_topic'] . '.' . $output['counter'] . ';msg=' . $output['id'],
1685 1685
 				'icon' => 'error',
1686 1686
 				'show' => $context['can_report_moderator']
1687 1687
 			),
1688 1688
 			'warn' => array(
1689 1689
 				'label' => $txt['issue_warning'],
1690
-				'href' => $scripturl.'?action=profile;area=issuewarning;u='.$output['member']['id'].';msg='.$output['id'],
1690
+				'href' => $scripturl . '?action=profile;area=issuewarning;u=' . $output['member']['id'] . ';msg=' . $output['id'],
1691 1691
 				'icon' => 'warn_button',
1692 1692
 				'show' => $context['can_issue_warning'] && !$output['is_message_author'] && !$output['member']['is_guest']
1693 1693
 			),
1694 1694
 			'restore' => array(
1695 1695
 				'label' => $txt['restore_message'],
1696
-				'href' => $scripturl.'?action=restoretopic;msgs='.$output['id'].';'.$context['session_var'].'='.$context['session_id'],
1696
+				'href' => $scripturl . '?action=restoretopic;msgs=' . $output['id'] . ';' . $context['session_var'] . '=' . $context['session_id'],
1697 1697
 				'icon' => 'restore_button',
1698 1698
 				'show' => $context['can_restore_msg']
1699 1699
 			),
1700 1700
 			'approve' => array(
1701 1701
 				'label' => $txt['approve'],
1702
-				'href' => $scripturl.'?action=moderate;area=postmod;sa=approve;topic='.$context['current_topic'].'.'.$context['start'].';msg='.$output['id'].';'.$context['session_var'].'='.$context['session_id'],
1702
+				'href' => $scripturl . '?action=moderate;area=postmod;sa=approve;topic=' . $context['current_topic'] . '.' . $context['start'] . ';msg=' . $output['id'] . ';' . $context['session_var'] . '=' . $context['session_id'],
1703 1703
 				'icon' => 'approve_button',
1704 1704
 				'show' => $output['can_approve']
1705 1705
 			),
1706 1706
 			'unapprove' => array(
1707 1707
 				'label' => $txt['unapprove'],
1708
-				'href' => $scripturl.'?action=moderate;area=postmod;sa=approve;topic='.$context['current_topic'].'.'.$context['start'].';msg='.$output['id'].';'.$context['session_var'].'='.$context['session_id'],
1708
+				'href' => $scripturl . '?action=moderate;area=postmod;sa=approve;topic=' . $context['current_topic'] . '.' . $context['start'] . ';msg=' . $output['id'] . ';' . $context['session_var'] . '=' . $context['session_id'],
1709 1709
 				'icon' => 'unapprove_button',
1710 1710
 				'show' => $output['can_unapprove']
1711 1711
 			),
1712 1712
 		),
1713 1713
 		'quickmod' => array(
1714
-			'id' => 'in_topic_mod_check_'. $output['id'],
1714
+			'id' => 'in_topic_mod_check_' . $output['id'],
1715 1715
 			'custom' => 'style="display: none;"',
1716 1716
 			'content' => '',
1717 1717
 			'show' => !empty($options['display_quick_mod']) && $options['display_quick_mod'] == 1 && $output['can_remove'],
Please login to merge, or discard this patch.
Sources/MessageIndex.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -330,7 +330,7 @@
 block discarded – undo
330 330
 		WHERE t.id_board = {int:current_board} '
331 331
 			. (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : '
332 332
 			AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') . (!empty($message_index_topic_wheres) ? ' 
333
-			AND ' . implode("\n\t\t\t\tAND ", $message_index_topic_wheres) : ''). '
333
+			AND ' . implode("\n\t\t\t\tAND ", $message_index_topic_wheres) : '') . '
334 334
 		ORDER BY is_sticky' . ($fake_ascending ? '' : ' DESC') . ', ' . $_REQUEST['sort'] . ($ascending ? '' : ' DESC') . '
335 335
 		LIMIT {int:maxindex}
336 336
 			OFFSET {int:start} ';
Please login to merge, or discard this patch.
Themes/default/index.template.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -574,7 +574,7 @@
 block discarded – undo
574 574
 				$value['id'] = $key;
575 575
 
576 576
 			$button = '
577
-				<a class="button button_strip_' . $key . (!empty($value['active']) ? ' active' : '') . (isset($value['class']) ? ' ' . $value['class'] : '') . '" ' . (!empty($value['url']) ? 'href="' . $value['url'] . '"' : '') . ' ' . (isset($value['custom']) ? ' ' . $value['custom'] : '') . '>'.(!empty($value['icon']) ? '<span class="main_icons '.$value['icon'].'"></span>' : '').'' . $txt[$value['text']] . '</a>';
577
+				<a class="button button_strip_' . $key . (!empty($value['active']) ? ' active' : '') . (isset($value['class']) ? ' ' . $value['class'] : '') . '" ' . (!empty($value['url']) ? 'href="' . $value['url'] . '"' : '') . ' ' . (isset($value['custom']) ? ' ' . $value['custom'] : '') . '>' . (!empty($value['icon']) ? '<span class="main_icons ' . $value['icon'] . '"></span>' : '') . '' . $txt[$value['text']] . '</a>';
578 578
 
579 579
 			if (!empty($value['sub_buttons']))
580 580
 			{
Please login to merge, or discard this patch.
Themes/default/PersonalMessage.template.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1931,7 +1931,7 @@
 block discarded – undo
1931 1931
 				<div class="floatright smalltext righttext">
1932 1932
 					<div class="recipient_to">&#171;&nbsp;<strong>', $txt['to'], ':</strong> ', implode(', ', $draft['recipients']['to']), '&nbsp;&#187;</div>';
1933 1933
 
1934
-			if(!empty($draft['recipients']['bcc']))
1934
+			if (!empty($draft['recipients']['bcc']))
1935 1935
 				echo'
1936 1936
 					<div class="pm_bbc">&#171;&nbsp;<strong>', $txt['pm_bcc'], ':</strong> ', implode(', ', $draft['recipients']['bcc']), '&nbsp;&#187;</div>';
1937 1937
 
Please login to merge, or discard this patch.
Sources/Post.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1241,7 +1241,7 @@
 block discarded – undo
1241 1241
 	// File Upload.
1242 1242
 	if ($context['can_post_attachment'])
1243 1243
 	{
1244
-		$acceptedFiles = empty($context['allowed_extensions']) ? '' : implode(',', array_map(function ($val) use ($smcFunc)
1244
+		$acceptedFiles = empty($context['allowed_extensions']) ? '' : implode(',', array_map(function($val) use ($smcFunc)
1245 1245
 		{
1246 1246
 			return !empty($val) ? ('.' . $smcFunc['htmltrim']($val)) : '';
1247 1247
 		}, explode(',', $context['allowed_extensions'])));
Please login to merge, or discard this patch.
Sources/Profile-Modify.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -500,7 +500,7 @@  discard block
 block discarded – undo
500 500
 						log_error(sprintf($txt['smiley_set_dir_not_found'], $set_names[array_search($set, $context['smiley_sets'])]));
501 501
 
502 502
 						$context['smiley_sets'] = array_filter($context['smiley_sets'], function($v) use ($set)
503
-							{
503
+						{
504 504
 								return $v != $set;
505 505
 							});
506 506
 					}
@@ -3467,7 +3467,6 @@  discard block
 block discarded – undo
3467 3467
 			}
3468 3468
 		}
3469 3469
 	}
3470
-
3471 3470
 	elseif (($value == 'upload' && allowedTo('profile_upload_avatar')) || $downloadedExternalAvatar)
3472 3471
 	{
3473 3472
 		if ((isset($_FILES['attachment']['name']) && $_FILES['attachment']['name'] != '') || $downloadedExternalAvatar)
Please login to merge, or discard this patch.
Sources/Notify.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -282,7 +282,7 @@
 block discarded – undo
282 282
 				'{db_prefix}log_notify',
283 283
 				array('id_member' => 'int', 'id_topic' => 'int', 'id_board' => 'int'),
284 284
 				array($user_info['id'], $log['id_topic'], 0),
285
-				array('id_member','id_topic', 'id_board')
285
+				array('id_member', 'id_topic', 'id_board')
286 286
 			);
287 287
 		}
288 288
 		else
Please login to merge, or discard this patch.
cron.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -310,7 +310,7 @@
 block discarded – undo
310 310
 {
311 311
 	/**
312 312
 	 * Constants for notification types.
313
-	*/
313
+	 */
314 314
 	const RECEIVE_NOTIFY_EMAIL = 0x02;
315 315
 	const RECEIVE_NOTIFY_ALERT = 0x01;
316 316
 
Please login to merge, or discard this patch.
Braces   -1 removed lines patch added patch discarded remove patch
@@ -93,7 +93,6 @@
 block discarded – undo
93 93
 	if ($ts <= 0 || $ts % 15 != 0 || time() - $ts < 0 || time() - $ts > 20)
94 94
 		obExit_cron();
95 95
 }
96
-
97 96
 else
98 97
 	$_SERVER['SERVER_PROTOCOL'] = 'HTTP/1.0';
99 98
 
Please login to merge, or discard this patch.