Failed Conditions
Push — release-2.1 ( e0848c...8d1977 )
by Rick
08:43
created
Sources/Subs.php 1 patch
Spacing   +30 added lines, -30 removed lines patch added patch discarded remove patch
@@ -395,7 +395,7 @@  discard block
 block discarded – undo
395 395
 			{
396 396
 				$val = 'CASE ';
397 397
 				foreach ($members as $k => $v)
398
-					$val .= 'WHEN id_member = ' . $v . ' THEN '. alert_count($v, true) . ' ';
398
+					$val .= 'WHEN id_member = ' . $v . ' THEN ' . alert_count($v, true) . ' ';
399 399
 				$val = $val . ' END';
400 400
 				$type = 'raw';
401 401
 			}
@@ -1055,11 +1055,11 @@  discard block
 block discarded – undo
1055 1055
 			// Anything that isn't a specification, punctuation mark, or whitespace.
1056 1056
 			'~(?<!%)\p{L}|[^\p{L}\p{P}\s]~u',
1057 1057
 			// A series of punctuation marks (except %), possibly separated by whitespace.
1058
-			'~([^%\P{P}])(\s*)(?'.'>(\1|[^%\P{Po}])\s*(?!$))*~u',
1058
+			'~([^%\P{P}])(\s*)(?' . '>(\1|[^%\P{Po}])\s*(?!$))*~u',
1059 1059
 			// Unwanted trailing punctuation and whitespace.
1060
-			'~(?'.'>([\p{Pd}\p{Ps}\p{Pi}\p{Pc}]|[^%\P{Po}])\s*)*$~u',
1060
+			'~(?' . '>([\p{Pd}\p{Ps}\p{Pi}\p{Pc}]|[^%\P{Po}])\s*)*$~u',
1061 1061
 			// Unwanted opening punctuation and whitespace.
1062
-			'~^\s*(?'.'>([\p{Pd}\p{Pe}\p{Pf}\p{Pc}]|[^%\P{Po}])\s*)*~u',
1062
+			'~^\s*(?' . '>([\p{Pd}\p{Pe}\p{Pf}\p{Pc}]|[^%\P{Po}])\s*)*~u',
1063 1063
 		),
1064 1064
 		array(
1065 1065
 			'',
@@ -1466,7 +1466,7 @@  discard block
 block discarded – undo
1466 1466
 							$width = !empty($width) ? ' width="' . $width . '"' : '';
1467 1467
 							$height = !empty($height) ? ' height="' . $height . '"' : '';
1468 1468
 
1469
-							$returnContext .= '<div class="videocontainer"><div><video controls preload="none" src="'. $currentAttachment['href'] . '" playsinline' . $width . $height . ' style="object-fit:contain;"><a href="' . $currentAttachment['href'] . '" class="bbc_link">' . $smcFunc['htmlspecialchars'](!empty($data) ? $data : $currentAttachment['name']) . '</a></video></div></div>' . (!empty($data) && $data != $currentAttachment['name'] ? '<div class="smalltext">' . $data . '</div>' : '');
1469
+							$returnContext .= '<div class="videocontainer"><div><video controls preload="none" src="' . $currentAttachment['href'] . '" playsinline' . $width . $height . ' style="object-fit:contain;"><a href="' . $currentAttachment['href'] . '" class="bbc_link">' . $smcFunc['htmlspecialchars'](!empty($data) ? $data : $currentAttachment['name']) . '</a></video></div></div>' . (!empty($data) && $data != $currentAttachment['name'] ? '<div class="smalltext">' . $data . '</div>' : '');
1470 1470
 						}
1471 1471
 						// Audio.
1472 1472
 						elseif (strpos($currentAttachment['mime_type'], 'audio/') === 0)
@@ -1474,7 +1474,7 @@  discard block
 block discarded – undo
1474 1474
 							$width = 'max-width:100%; width: ' . (!empty($width) ? $width : '400') . 'px;';
1475 1475
 							$height = !empty($height) ? 'height: ' . $height . 'px;' : '';
1476 1476
 
1477
-							$returnContext .= (!empty($data) && $data != $currentAttachment['name'] ? $data . ' ' : '') . '<audio controls preload="none" src="'. $currentAttachment['href'] . '" class="bbc_audio" style="vertical-align:middle;' . $width . $height . '"><a href="' . $currentAttachment['href'] . '" class="bbc_link">' . $smcFunc['htmlspecialchars'](!empty($data) ? $data : $currentAttachment['name']) . '</a></audio>';
1477
+							$returnContext .= (!empty($data) && $data != $currentAttachment['name'] ? $data . ' ' : '') . '<audio controls preload="none" src="' . $currentAttachment['href'] . '" class="bbc_audio" style="vertical-align:middle;' . $width . $height . '"><a href="' . $currentAttachment['href'] . '" class="bbc_link">' . $smcFunc['htmlspecialchars'](!empty($data) ? $data : $currentAttachment['name']) . '</a></audio>';
1478 1478
 						}
1479 1479
 						// Anything else.
1480 1480
 						else
@@ -1637,7 +1637,7 @@  discard block
 block discarded – undo
1637 1637
 				'type' => 'unparsed_commas_content',
1638 1638
 				'test' => '\d+,\d+\]',
1639 1639
 				'content' => '<a href="$1" target="_blank" rel="noopener">$1</a>',
1640
-				'validate' => function (&$tag, &$data, $disabled)
1640
+				'validate' => function(&$tag, &$data, $disabled)
1641 1641
 				{
1642 1642
 					$scheme = parse_url($data[0], PHP_URL_SCHEME);
1643 1643
 					if (empty($scheme))
@@ -2197,7 +2197,7 @@  discard block
 block discarded – undo
2197 2197
 		$codes[] = array(
2198 2198
 			'tag' => 'cowsay',
2199 2199
 			'parameters' => array(
2200
-				'e' => array('optional' => true, 'quoted' => true, 'match' => '(.*?)', 'default' => 'oo', 'validate' => function ($eyes) use ($smcFunc)
2200
+				'e' => array('optional' => true, 'quoted' => true, 'match' => '(.*?)', 'default' => 'oo', 'validate' => function($eyes) use ($smcFunc)
2201 2201
 					{
2202 2202
 						static $css_added;
2203 2203
 
@@ -2214,7 +2214,7 @@  discard block
 block discarded – undo
2214 2214
 						return $smcFunc['substr']($eyes . 'oo', 0, 2);
2215 2215
 					},
2216 2216
 				),
2217
-				't' => array('optional' => true, 'quoted' => true, 'match' => '(.*?)', 'default' => '  ', 'validate' => function ($tongue) use ($smcFunc)
2217
+				't' => array('optional' => true, 'quoted' => true, 'match' => '(.*?)', 'default' => '  ', 'validate' => function($tongue) use ($smcFunc)
2218 2218
 					{
2219 2219
 						return $smcFunc['substr']($tongue . '  ', 0, 2);
2220 2220
 					},
@@ -4178,7 +4178,7 @@  discard block
 block discarded – undo
4178 4178
 	$toMinify = array();
4179 4179
 	$normal = array();
4180 4180
 
4181
-	usort($context['css_files'], function ($a, $b)
4181
+	usort($context['css_files'], function($a, $b)
4182 4182
 	{
4183 4183
 		return $a['options']['order_pos'] < $b['options']['order_pos'] ? -1 : ($a['options']['order_pos'] > $b['options']['order_pos'] ? 1 : 0);
4184 4184
 	});
@@ -5643,13 +5643,13 @@  discard block
 block discarded – undo
5643 5643
 
5644 5644
 	// UTF-8 occurences of MS special characters
5645 5645
 	$findchars_utf8 = array(
5646
-		"\xe2\x80\x9a",	// single low-9 quotation mark
5647
-		"\xe2\x80\x9e",	// double low-9 quotation mark
5648
-		"\xe2\x80\xa6",	// horizontal ellipsis
5649
-		"\xe2\x80\x98",	// left single curly quote
5650
-		"\xe2\x80\x99",	// right single curly quote
5651
-		"\xe2\x80\x9c",	// left double curly quote
5652
-		"\xe2\x80\x9d",	// right double curly quote
5646
+		"\xe2\x80\x9a", // single low-9 quotation mark
5647
+		"\xe2\x80\x9e", // double low-9 quotation mark
5648
+		"\xe2\x80\xa6", // horizontal ellipsis
5649
+		"\xe2\x80\x98", // left single curly quote
5650
+		"\xe2\x80\x99", // right single curly quote
5651
+		"\xe2\x80\x9c", // left double curly quote
5652
+		"\xe2\x80\x9d", // right double curly quote
5653 5653
 	);
5654 5654
 
5655 5655
 	// windows 1252 / iso equivalents
@@ -5665,13 +5665,13 @@  discard block
 block discarded – undo
5665 5665
 
5666 5666
 	// safe replacements
5667 5667
 	$replacechars = array(
5668
-		',',	// &sbquo;
5669
-		',,',	// &bdquo;
5670
-		'...',	// &hellip;
5671
-		"'",	// &lsquo;
5672
-		"'",	// &rsquo;
5673
-		'"',	// &ldquo;
5674
-		'"',	// &rdquo;
5668
+		',', // &sbquo;
5669
+		',,', // &bdquo;
5670
+		'...', // &hellip;
5671
+		"'", // &lsquo;
5672
+		"'", // &rsquo;
5673
+		'"', // &ldquo;
5674
+		'"', // &rdquo;
5675 5675
 	);
5676 5676
 
5677 5677
 	if ($context['utf8'])
@@ -6845,7 +6845,7 @@  discard block
 block discarded – undo
6845 6845
 			EXISTS (
6846 6846
 				SELECT bpv.id_board
6847 6847
 				FROM ' . $db_prefix . 'board_permissions_view AS bpv
6848
-				WHERE bpv.id_group IN ('. implode(',', $groups) .')
6848
+				WHERE bpv.id_group IN ('. implode(',', $groups) . ')
6849 6849
 					AND bpv.deny = 0
6850 6850
 					AND bpv.id_board = b.id_board
6851 6851
 			)';
@@ -6855,7 +6855,7 @@  discard block
 block discarded – undo
6855 6855
 			AND NOT EXISTS (
6856 6856
 				SELECT bpv.id_board
6857 6857
 				FROM ' . $db_prefix . 'board_permissions_view AS bpv
6858
-				WHERE bpv.id_group IN ( '. implode(',', $groups) .')
6858
+				WHERE bpv.id_group IN ( '. implode(',', $groups) . ')
6859 6859
 					AND bpv.deny = 1
6860 6860
 					AND bpv.id_board = b.id_board
6861 6861
 			)';
@@ -7126,8 +7126,8 @@  discard block
 block discarded – undo
7126 7126
 	$i = 0;
7127 7127
 	while (empty($done))
7128 7128
 	{
7129
-		if (strpos($format, '{'. --$i . '}') !== false)
7130
-			$replacements['{'. $i . '}'] = array_pop($list);
7129
+		if (strpos($format, '{' . --$i . '}') !== false)
7130
+			$replacements['{' . $i . '}'] = array_pop($list);
7131 7131
 		else
7132 7132
 			$done = true;
7133 7133
 	}
@@ -7137,8 +7137,8 @@  discard block
 block discarded – undo
7137 7137
 	$i = 0;
7138 7138
 	while (empty($done))
7139 7139
 	{
7140
-		if (strpos($format, '{'. ++$i . '}') !== false)
7141
-			$replacements['{'. $i . '}'] = array_shift($list);
7140
+		if (strpos($format, '{' . ++$i . '}') !== false)
7141
+			$replacements['{' . $i . '}'] = array_shift($list);
7142 7142
 		else
7143 7143
 			$done = true;
7144 7144
 	}
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.
Sources/Notify.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -154,7 +154,7 @@
 block discarded – undo
154 154
 					'{db_prefix}log_notify',
155 155
 					array('id_member' => 'int', 'id_topic' => 'int', 'id_board' => 'int'),
156 156
 					array($user_info['id'], $log['id_topic'], 0),
157
-					array('id_member','id_topic', 'id_board')
157
+					array('id_member', 'id_topic', 'id_board')
158 158
 				);
159 159
 			}
160 160
 			else
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.