Completed
Push — release-2.1 ( 4c82a0...64d581 )
by Rick
09:29
created
other/upgrade.php 1 patch
Spacing   +112 added lines, -112 removed lines patch added patch discarded remove patch
@@ -426,11 +426,11 @@  discard block
 block discarded – undo
426 426
 
427 427
 		$totalTime = '';
428 428
 		if ($hours > 0)
429
-			$totalTime .= $hours . ' hour' . ($hours > 1 ? 's':'') . ' ';
429
+			$totalTime .= $hours . ' hour' . ($hours > 1 ? 's' : '') . ' ';
430 430
 		if ($minutes > 0)
431
-			$totalTime .= $minutes . ' minute' . ($minutes > 1 ? 's':'') . ' ';
431
+			$totalTime .= $minutes . ' minute' . ($minutes > 1 ? 's' : '') . ' ';
432 432
 		if ($seconds > 0)
433
-			$totalTime .= $seconds . ' second' . ($seconds > 1 ? 's':'') . ' ';
433
+			$totalTime .= $seconds . ' second' . ($seconds > 1 ? 's' : '') . ' ';
434 434
 
435 435
 		if (!empty($totalTime))
436 436
 			echo "\n" . 'Upgrade completed in ' . $totalTime . "\n";
@@ -709,14 +709,14 @@  discard block
 block discarded – undo
709 709
 	// Do we need to add this setting?
710 710
 	$need_settings_update = empty($modSettings['custom_avatar_dir']);
711 711
 
712
-	$custom_av_dir = !empty($modSettings['custom_avatar_dir']) ? $modSettings['custom_avatar_dir'] : $GLOBALS['boarddir'] .'/custom_avatar';
713
-	$custom_av_url = !empty($modSettings['custom_avatar_url']) ? $modSettings['custom_avatar_url'] : $boardurl .'/custom_avatar';
712
+	$custom_av_dir = !empty($modSettings['custom_avatar_dir']) ? $modSettings['custom_avatar_dir'] : $GLOBALS['boarddir'] . '/custom_avatar';
713
+	$custom_av_url = !empty($modSettings['custom_avatar_url']) ? $modSettings['custom_avatar_url'] : $boardurl . '/custom_avatar';
714 714
 
715 715
 	// This little fellow has to cooperate...
716 716
 	quickFileWritable($custom_av_dir);
717 717
 
718 718
 	// Are we good now?
719
-	if(!is_writable($custom_av_dir))
719
+	if (!is_writable($custom_av_dir))
720 720
 		return throw_error(sprintf('The directory: %1$s has to be writable to continue the upgrade. Please make sure permissions are correctly set to allow this.', $custom_av_dir));
721 721
 	elseif ($need_settings_update)
722 722
 	{
@@ -912,7 +912,7 @@  discard block
 block discarded – undo
912 912
 				$upcontext['user']['id'] = 1;
913 913
 				$upcontext['user']['name'] = 'Administrator';
914 914
 			}
915
-			$upcontext['user']['pass'] = mt_rand(0,60000);
915
+			$upcontext['user']['pass'] = mt_rand(0, 60000);
916 916
 			// This basically is used to match the GET variables to Settings.php.
917 917
 			$upcontext['upgrade_status']['pass'] = $upcontext['user']['pass'];
918 918
 
@@ -1123,7 +1123,7 @@  discard block
 block discarded – undo
1123 1123
 		if ($db_port != ini_get('mysql' . ($db_type == 'mysqli' || !empty($_POST['convertMysql']) ? 'i' : '') . '.default_port'))
1124 1124
 			$changes['db_port'] = (int) $db_port;
1125 1125
 	}
1126
-	elseif(!empty($db_port))
1126
+	elseif (!empty($db_port))
1127 1127
 	{
1128 1128
 		// If db_port is set and is the same as the default, set it to ''
1129 1129
 		if ($db_type == 'mysql' || $db_type == 'mysqli')
@@ -1727,7 +1727,7 @@  discard block
 block discarded – undo
1727 1727
 		}
1728 1728
 
1729 1729
 		if (!empty($deletes))
1730
-			upgrade_query( '
1730
+			upgrade_query('
1731 1731
 				UPDATE ' . $db_prefix . 'log_packages
1732 1732
 				SET install_state = 0
1733 1733
 				WHERE id_install IN (' . implode(',', $deletes) . ')');
@@ -1806,7 +1806,7 @@  discard block
 block discarded – undo
1806 1806
 	else
1807 1807
 	{
1808 1808
 		require_once($sourcedir . '/ScheduledTasks.php');
1809
-		$forum_version = SMF_VERSION;  // The variable is usually defined in index.php so lets just use the constant to do it for us.
1809
+		$forum_version = SMF_VERSION; // The variable is usually defined in index.php so lets just use the constant to do it for us.
1810 1810
 		scheduled_fetchSMfiles(); // Now go get those files!
1811 1811
 	}
1812 1812
 
@@ -2624,7 +2624,7 @@  discard block
 block discarded – undo
2624 2624
 	}
2625 2625
 	elseif ($change['type'] === 'index')
2626 2626
 	{
2627
-		$request = upgrade_query( '
2627
+		$request = upgrade_query('
2628 2628
 			SHOW INDEX
2629 2629
 			FROM ' . $db_prefix . $change['table']);
2630 2630
 		if ($request !== false)
@@ -3271,7 +3271,7 @@  discard block
 block discarded – undo
3271 3271
 	// Try 755 and 775 first since 777 doesn't always work and could be a risk...
3272 3272
 	$chmod_values = array(0755, 0775, 0777);
3273 3273
 
3274
-	foreach($chmod_values as $val)
3274
+	foreach ($chmod_values as $val)
3275 3275
 	{
3276 3276
 		// If it's writable, break out of the loop
3277 3277
 		if (is_writable($file))
@@ -3481,95 +3481,95 @@  discard block
 block discarded – undo
3481 3481
 		// Translation table for the character sets not native for MySQL.
3482 3482
 		$translation_tables = array(
3483 3483
 			'windows-1255' => array(
3484
-				'0x81' => '\'\'',		'0x8A' => '\'\'',		'0x8C' => '\'\'',
3485
-				'0x8D' => '\'\'',		'0x8E' => '\'\'',		'0x8F' => '\'\'',
3486
-				'0x90' => '\'\'',		'0x9A' => '\'\'',		'0x9C' => '\'\'',
3487
-				'0x9D' => '\'\'',		'0x9E' => '\'\'',		'0x9F' => '\'\'',
3488
-				'0xCA' => '\'\'',		'0xD9' => '\'\'',		'0xDA' => '\'\'',
3489
-				'0xDB' => '\'\'',		'0xDC' => '\'\'',		'0xDD' => '\'\'',
3490
-				'0xDE' => '\'\'',		'0xDF' => '\'\'',		'0xFB' => '\'\'',
3491
-				'0xFC' => '\'\'',		'0xFF' => '\'\'',		'0xC2' => '0xFF',
3492
-				'0x80' => '0xFC',		'0xE2' => '0xFB',		'0xA0' => '0xC2A0',
3493
-				'0xA1' => '0xC2A1',		'0xA2' => '0xC2A2',		'0xA3' => '0xC2A3',
3494
-				'0xA5' => '0xC2A5',		'0xA6' => '0xC2A6',		'0xA7' => '0xC2A7',
3495
-				'0xA8' => '0xC2A8',		'0xA9' => '0xC2A9',		'0xAB' => '0xC2AB',
3496
-				'0xAC' => '0xC2AC',		'0xAD' => '0xC2AD',		'0xAE' => '0xC2AE',
3497
-				'0xAF' => '0xC2AF',		'0xB0' => '0xC2B0',		'0xB1' => '0xC2B1',
3498
-				'0xB2' => '0xC2B2',		'0xB3' => '0xC2B3',		'0xB4' => '0xC2B4',
3499
-				'0xB5' => '0xC2B5',		'0xB6' => '0xC2B6',		'0xB7' => '0xC2B7',
3500
-				'0xB8' => '0xC2B8',		'0xB9' => '0xC2B9',		'0xBB' => '0xC2BB',
3501
-				'0xBC' => '0xC2BC',		'0xBD' => '0xC2BD',		'0xBE' => '0xC2BE',
3502
-				'0xBF' => '0xC2BF',		'0xD7' => '0xD7B3',		'0xD1' => '0xD781',
3503
-				'0xD4' => '0xD7B0',		'0xD5' => '0xD7B1',		'0xD6' => '0xD7B2',
3504
-				'0xE0' => '0xD790',		'0xEA' => '0xD79A',		'0xEC' => '0xD79C',
3505
-				'0xED' => '0xD79D',		'0xEE' => '0xD79E',		'0xEF' => '0xD79F',
3506
-				'0xF0' => '0xD7A0',		'0xF1' => '0xD7A1',		'0xF2' => '0xD7A2',
3507
-				'0xF3' => '0xD7A3',		'0xF5' => '0xD7A5',		'0xF6' => '0xD7A6',
3508
-				'0xF7' => '0xD7A7',		'0xF8' => '0xD7A8',		'0xF9' => '0xD7A9',
3509
-				'0x82' => '0xE2809A',	'0x84' => '0xE2809E',	'0x85' => '0xE280A6',
3510
-				'0x86' => '0xE280A0',	'0x87' => '0xE280A1',	'0x89' => '0xE280B0',
3511
-				'0x8B' => '0xE280B9',	'0x93' => '0xE2809C',	'0x94' => '0xE2809D',
3512
-				'0x95' => '0xE280A2',	'0x97' => '0xE28094',	'0x99' => '0xE284A2',
3513
-				'0xC0' => '0xD6B0',		'0xC1' => '0xD6B1',		'0xC3' => '0xD6B3',
3514
-				'0xC4' => '0xD6B4',		'0xC5' => '0xD6B5',		'0xC6' => '0xD6B6',
3515
-				'0xC7' => '0xD6B7',		'0xC8' => '0xD6B8',		'0xC9' => '0xD6B9',
3516
-				'0xCB' => '0xD6BB',		'0xCC' => '0xD6BC',		'0xCD' => '0xD6BD',
3517
-				'0xCE' => '0xD6BE',		'0xCF' => '0xD6BF',		'0xD0' => '0xD780',
3518
-				'0xD2' => '0xD782',		'0xE3' => '0xD793',		'0xE4' => '0xD794',
3519
-				'0xE5' => '0xD795',		'0xE7' => '0xD797',		'0xE9' => '0xD799',
3520
-				'0xFD' => '0xE2808E',	'0xFE' => '0xE2808F',	'0x92' => '0xE28099',
3521
-				'0x83' => '0xC692',		'0xD3' => '0xD783',		'0x88' => '0xCB86',
3522
-				'0x98' => '0xCB9C',		'0x91' => '0xE28098',	'0x96' => '0xE28093',
3523
-				'0xBA' => '0xC3B7',		'0x9B' => '0xE280BA',	'0xAA' => '0xC397',
3524
-				'0xA4' => '0xE282AA',	'0xE1' => '0xD791',		'0xE6' => '0xD796',
3525
-				'0xE8' => '0xD798',		'0xEB' => '0xD79B',		'0xF4' => '0xD7A4',
3526
-				'0xFA' => '0xD7AA',		'0xFF' => '0xD6B2',		'0xFC' => '0xE282AC',
3484
+				'0x81' => '\'\'', '0x8A' => '\'\'', '0x8C' => '\'\'',
3485
+				'0x8D' => '\'\'', '0x8E' => '\'\'', '0x8F' => '\'\'',
3486
+				'0x90' => '\'\'', '0x9A' => '\'\'', '0x9C' => '\'\'',
3487
+				'0x9D' => '\'\'', '0x9E' => '\'\'', '0x9F' => '\'\'',
3488
+				'0xCA' => '\'\'', '0xD9' => '\'\'', '0xDA' => '\'\'',
3489
+				'0xDB' => '\'\'', '0xDC' => '\'\'', '0xDD' => '\'\'',
3490
+				'0xDE' => '\'\'', '0xDF' => '\'\'', '0xFB' => '\'\'',
3491
+				'0xFC' => '\'\'', '0xFF' => '\'\'', '0xC2' => '0xFF',
3492
+				'0x80' => '0xFC', '0xE2' => '0xFB', '0xA0' => '0xC2A0',
3493
+				'0xA1' => '0xC2A1', '0xA2' => '0xC2A2', '0xA3' => '0xC2A3',
3494
+				'0xA5' => '0xC2A5', '0xA6' => '0xC2A6', '0xA7' => '0xC2A7',
3495
+				'0xA8' => '0xC2A8', '0xA9' => '0xC2A9', '0xAB' => '0xC2AB',
3496
+				'0xAC' => '0xC2AC', '0xAD' => '0xC2AD', '0xAE' => '0xC2AE',
3497
+				'0xAF' => '0xC2AF', '0xB0' => '0xC2B0', '0xB1' => '0xC2B1',
3498
+				'0xB2' => '0xC2B2', '0xB3' => '0xC2B3', '0xB4' => '0xC2B4',
3499
+				'0xB5' => '0xC2B5', '0xB6' => '0xC2B6', '0xB7' => '0xC2B7',
3500
+				'0xB8' => '0xC2B8', '0xB9' => '0xC2B9', '0xBB' => '0xC2BB',
3501
+				'0xBC' => '0xC2BC', '0xBD' => '0xC2BD', '0xBE' => '0xC2BE',
3502
+				'0xBF' => '0xC2BF', '0xD7' => '0xD7B3', '0xD1' => '0xD781',
3503
+				'0xD4' => '0xD7B0', '0xD5' => '0xD7B1', '0xD6' => '0xD7B2',
3504
+				'0xE0' => '0xD790', '0xEA' => '0xD79A', '0xEC' => '0xD79C',
3505
+				'0xED' => '0xD79D', '0xEE' => '0xD79E', '0xEF' => '0xD79F',
3506
+				'0xF0' => '0xD7A0', '0xF1' => '0xD7A1', '0xF2' => '0xD7A2',
3507
+				'0xF3' => '0xD7A3', '0xF5' => '0xD7A5', '0xF6' => '0xD7A6',
3508
+				'0xF7' => '0xD7A7', '0xF8' => '0xD7A8', '0xF9' => '0xD7A9',
3509
+				'0x82' => '0xE2809A', '0x84' => '0xE2809E', '0x85' => '0xE280A6',
3510
+				'0x86' => '0xE280A0', '0x87' => '0xE280A1', '0x89' => '0xE280B0',
3511
+				'0x8B' => '0xE280B9', '0x93' => '0xE2809C', '0x94' => '0xE2809D',
3512
+				'0x95' => '0xE280A2', '0x97' => '0xE28094', '0x99' => '0xE284A2',
3513
+				'0xC0' => '0xD6B0', '0xC1' => '0xD6B1', '0xC3' => '0xD6B3',
3514
+				'0xC4' => '0xD6B4', '0xC5' => '0xD6B5', '0xC6' => '0xD6B6',
3515
+				'0xC7' => '0xD6B7', '0xC8' => '0xD6B8', '0xC9' => '0xD6B9',
3516
+				'0xCB' => '0xD6BB', '0xCC' => '0xD6BC', '0xCD' => '0xD6BD',
3517
+				'0xCE' => '0xD6BE', '0xCF' => '0xD6BF', '0xD0' => '0xD780',
3518
+				'0xD2' => '0xD782', '0xE3' => '0xD793', '0xE4' => '0xD794',
3519
+				'0xE5' => '0xD795', '0xE7' => '0xD797', '0xE9' => '0xD799',
3520
+				'0xFD' => '0xE2808E', '0xFE' => '0xE2808F', '0x92' => '0xE28099',
3521
+				'0x83' => '0xC692', '0xD3' => '0xD783', '0x88' => '0xCB86',
3522
+				'0x98' => '0xCB9C', '0x91' => '0xE28098', '0x96' => '0xE28093',
3523
+				'0xBA' => '0xC3B7', '0x9B' => '0xE280BA', '0xAA' => '0xC397',
3524
+				'0xA4' => '0xE282AA', '0xE1' => '0xD791', '0xE6' => '0xD796',
3525
+				'0xE8' => '0xD798', '0xEB' => '0xD79B', '0xF4' => '0xD7A4',
3526
+				'0xFA' => '0xD7AA', '0xFF' => '0xD6B2', '0xFC' => '0xE282AC',
3527 3527
 				'0xFB' => '0xD792',
3528 3528
 			),
3529 3529
 			'windows-1253' => array(
3530
-				'0x81' => '\'\'',			'0x88' => '\'\'',			'0x8A' => '\'\'',
3531
-				'0x8C' => '\'\'',			'0x8D' => '\'\'',			'0x8E' => '\'\'',
3532
-				'0x8F' => '\'\'',			'0x90' => '\'\'',			'0x98' => '\'\'',
3533
-				'0x9A' => '\'\'',			'0x9C' => '\'\'',			'0x9D' => '\'\'',
3534
-				'0x9E' => '\'\'',			'0x9F' => '\'\'',			'0xAA' => '\'\'',
3535
-				'0xD2' => '\'\'',			'0xFF' => '\'\'',			'0xCE' => '0xCE9E',
3536
-				'0xB8' => '0xCE88',		'0xBA' => '0xCE8A',		'0xBC' => '0xCE8C',
3537
-				'0xBE' => '0xCE8E',		'0xBF' => '0xCE8F',		'0xC0' => '0xCE90',
3538
-				'0xC8' => '0xCE98',		'0xCA' => '0xCE9A',		'0xCC' => '0xCE9C',
3539
-				'0xCD' => '0xCE9D',		'0xCF' => '0xCE9F',		'0xDA' => '0xCEAA',
3540
-				'0xE8' => '0xCEB8',		'0xEA' => '0xCEBA',		'0xEC' => '0xCEBC',
3541
-				'0xEE' => '0xCEBE',		'0xEF' => '0xCEBF',		'0xC2' => '0xFF',
3542
-				'0xBD' => '0xC2BD',		'0xED' => '0xCEBD',		'0xB2' => '0xC2B2',
3543
-				'0xA0' => '0xC2A0',		'0xA3' => '0xC2A3',		'0xA4' => '0xC2A4',
3544
-				'0xA5' => '0xC2A5',		'0xA6' => '0xC2A6',		'0xA7' => '0xC2A7',
3545
-				'0xA8' => '0xC2A8',		'0xA9' => '0xC2A9',		'0xAB' => '0xC2AB',
3546
-				'0xAC' => '0xC2AC',		'0xAD' => '0xC2AD',		'0xAE' => '0xC2AE',
3547
-				'0xB0' => '0xC2B0',		'0xB1' => '0xC2B1',		'0xB3' => '0xC2B3',
3548
-				'0xB5' => '0xC2B5',		'0xB6' => '0xC2B6',		'0xB7' => '0xC2B7',
3549
-				'0xBB' => '0xC2BB',		'0xE2' => '0xCEB2',		'0x80' => '0xD2',
3550
-				'0x82' => '0xE2809A',	'0x84' => '0xE2809E',	'0x85' => '0xE280A6',
3551
-				'0x86' => '0xE280A0',	'0xA1' => '0xCE85',		'0xA2' => '0xCE86',
3552
-				'0x87' => '0xE280A1',	'0x89' => '0xE280B0',	'0xB9' => '0xCE89',
3553
-				'0x8B' => '0xE280B9',	'0x91' => '0xE28098',	'0x99' => '0xE284A2',
3554
-				'0x92' => '0xE28099',	'0x93' => '0xE2809C',	'0x94' => '0xE2809D',
3555
-				'0x95' => '0xE280A2',	'0x96' => '0xE28093',	'0x97' => '0xE28094',
3556
-				'0x9B' => '0xE280BA',	'0xAF' => '0xE28095',	'0xB4' => '0xCE84',
3557
-				'0xC1' => '0xCE91',		'0xC3' => '0xCE93',		'0xC4' => '0xCE94',
3558
-				'0xC5' => '0xCE95',		'0xC6' => '0xCE96',		'0x83' => '0xC692',
3559
-				'0xC7' => '0xCE97',		'0xC9' => '0xCE99',		'0xCB' => '0xCE9B',
3560
-				'0xD0' => '0xCEA0',		'0xD1' => '0xCEA1',		'0xD3' => '0xCEA3',
3561
-				'0xD4' => '0xCEA4',		'0xD5' => '0xCEA5',		'0xD6' => '0xCEA6',
3562
-				'0xD7' => '0xCEA7',		'0xD8' => '0xCEA8',		'0xD9' => '0xCEA9',
3563
-				'0xDB' => '0xCEAB',		'0xDC' => '0xCEAC',		'0xDD' => '0xCEAD',
3564
-				'0xDE' => '0xCEAE',		'0xDF' => '0xCEAF',		'0xE0' => '0xCEB0',
3565
-				'0xE1' => '0xCEB1',		'0xE3' => '0xCEB3',		'0xE4' => '0xCEB4',
3566
-				'0xE5' => '0xCEB5',		'0xE6' => '0xCEB6',		'0xE7' => '0xCEB7',
3567
-				'0xE9' => '0xCEB9',		'0xEB' => '0xCEBB',		'0xF0' => '0xCF80',
3568
-				'0xF1' => '0xCF81',		'0xF2' => '0xCF82',		'0xF3' => '0xCF83',
3569
-				'0xF4' => '0xCF84',		'0xF5' => '0xCF85',		'0xF6' => '0xCF86',
3570
-				'0xF7' => '0xCF87',		'0xF8' => '0xCF88',		'0xF9' => '0xCF89',
3571
-				'0xFA' => '0xCF8A',		'0xFB' => '0xCF8B',		'0xFC' => '0xCF8C',
3572
-				'0xFD' => '0xCF8D',		'0xFE' => '0xCF8E',		'0xFF' => '0xCE92',
3530
+				'0x81' => '\'\'', '0x88' => '\'\'', '0x8A' => '\'\'',
3531
+				'0x8C' => '\'\'', '0x8D' => '\'\'', '0x8E' => '\'\'',
3532
+				'0x8F' => '\'\'', '0x90' => '\'\'', '0x98' => '\'\'',
3533
+				'0x9A' => '\'\'', '0x9C' => '\'\'', '0x9D' => '\'\'',
3534
+				'0x9E' => '\'\'', '0x9F' => '\'\'', '0xAA' => '\'\'',
3535
+				'0xD2' => '\'\'', '0xFF' => '\'\'', '0xCE' => '0xCE9E',
3536
+				'0xB8' => '0xCE88', '0xBA' => '0xCE8A', '0xBC' => '0xCE8C',
3537
+				'0xBE' => '0xCE8E', '0xBF' => '0xCE8F', '0xC0' => '0xCE90',
3538
+				'0xC8' => '0xCE98', '0xCA' => '0xCE9A', '0xCC' => '0xCE9C',
3539
+				'0xCD' => '0xCE9D', '0xCF' => '0xCE9F', '0xDA' => '0xCEAA',
3540
+				'0xE8' => '0xCEB8', '0xEA' => '0xCEBA', '0xEC' => '0xCEBC',
3541
+				'0xEE' => '0xCEBE', '0xEF' => '0xCEBF', '0xC2' => '0xFF',
3542
+				'0xBD' => '0xC2BD', '0xED' => '0xCEBD', '0xB2' => '0xC2B2',
3543
+				'0xA0' => '0xC2A0', '0xA3' => '0xC2A3', '0xA4' => '0xC2A4',
3544
+				'0xA5' => '0xC2A5', '0xA6' => '0xC2A6', '0xA7' => '0xC2A7',
3545
+				'0xA8' => '0xC2A8', '0xA9' => '0xC2A9', '0xAB' => '0xC2AB',
3546
+				'0xAC' => '0xC2AC', '0xAD' => '0xC2AD', '0xAE' => '0xC2AE',
3547
+				'0xB0' => '0xC2B0', '0xB1' => '0xC2B1', '0xB3' => '0xC2B3',
3548
+				'0xB5' => '0xC2B5', '0xB6' => '0xC2B6', '0xB7' => '0xC2B7',
3549
+				'0xBB' => '0xC2BB', '0xE2' => '0xCEB2', '0x80' => '0xD2',
3550
+				'0x82' => '0xE2809A', '0x84' => '0xE2809E', '0x85' => '0xE280A6',
3551
+				'0x86' => '0xE280A0', '0xA1' => '0xCE85', '0xA2' => '0xCE86',
3552
+				'0x87' => '0xE280A1', '0x89' => '0xE280B0', '0xB9' => '0xCE89',
3553
+				'0x8B' => '0xE280B9', '0x91' => '0xE28098', '0x99' => '0xE284A2',
3554
+				'0x92' => '0xE28099', '0x93' => '0xE2809C', '0x94' => '0xE2809D',
3555
+				'0x95' => '0xE280A2', '0x96' => '0xE28093', '0x97' => '0xE28094',
3556
+				'0x9B' => '0xE280BA', '0xAF' => '0xE28095', '0xB4' => '0xCE84',
3557
+				'0xC1' => '0xCE91', '0xC3' => '0xCE93', '0xC4' => '0xCE94',
3558
+				'0xC5' => '0xCE95', '0xC6' => '0xCE96', '0x83' => '0xC692',
3559
+				'0xC7' => '0xCE97', '0xC9' => '0xCE99', '0xCB' => '0xCE9B',
3560
+				'0xD0' => '0xCEA0', '0xD1' => '0xCEA1', '0xD3' => '0xCEA3',
3561
+				'0xD4' => '0xCEA4', '0xD5' => '0xCEA5', '0xD6' => '0xCEA6',
3562
+				'0xD7' => '0xCEA7', '0xD8' => '0xCEA8', '0xD9' => '0xCEA9',
3563
+				'0xDB' => '0xCEAB', '0xDC' => '0xCEAC', '0xDD' => '0xCEAD',
3564
+				'0xDE' => '0xCEAE', '0xDF' => '0xCEAF', '0xE0' => '0xCEB0',
3565
+				'0xE1' => '0xCEB1', '0xE3' => '0xCEB3', '0xE4' => '0xCEB4',
3566
+				'0xE5' => '0xCEB5', '0xE6' => '0xCEB6', '0xE7' => '0xCEB7',
3567
+				'0xE9' => '0xCEB9', '0xEB' => '0xCEBB', '0xF0' => '0xCF80',
3568
+				'0xF1' => '0xCF81', '0xF2' => '0xCF82', '0xF3' => '0xCF83',
3569
+				'0xF4' => '0xCF84', '0xF5' => '0xCF85', '0xF6' => '0xCF86',
3570
+				'0xF7' => '0xCF87', '0xF8' => '0xCF88', '0xF9' => '0xCF89',
3571
+				'0xFA' => '0xCF8A', '0xFB' => '0xCF8B', '0xFC' => '0xCF8C',
3572
+				'0xFD' => '0xCF8D', '0xFE' => '0xCF8E', '0xFF' => '0xCE92',
3573 3573
 				'0xD2' => '0xE282AC',
3574 3574
 			),
3575 3575
 		);
@@ -3591,7 +3591,7 @@  discard block
 block discarded – undo
3591 3591
 		$upcontext['table_count'] = count($queryTables);
3592 3592
 		$file_steps = $upcontext['table_count'];
3593 3593
 
3594
-		for($substep = $_GET['substep']; $substep < $upcontext['table_count']; $substep++)
3594
+		for ($substep = $_GET['substep']; $substep < $upcontext['table_count']; $substep++)
3595 3595
 		{
3596 3596
 			$table = $queryTables[$_GET['substep']];
3597 3597
 
@@ -3819,7 +3819,7 @@  discard block
 block discarded – undo
3819 3819
 	$upcontext['step_progress'] = (int) (($upcontext['cur_table_num'] / $upcontext['table_count']) * 100);
3820 3820
 	$file_steps = $upcontext['table_count'];
3821 3821
 
3822
-	foreach($keys as $id => $table)
3822
+	foreach ($keys as $id => $table)
3823 3823
 		if ($id < $_GET['substep'])
3824 3824
 			$upcontext['previous_tables'][] = $table;
3825 3825
 
@@ -3834,7 +3834,7 @@  discard block
 block discarded – undo
3834 3834
 			$upcontext['cur_table_name'] = isset($keys[$substep + 1]) ? $keys[$substep + 1] : $keys[$substep];
3835 3835
 			$upcontext['cur_table_num'] = $substep + 1;
3836 3836
 
3837
-			$upcontext['step_progress'] = (int)(($upcontext['cur_table_num'] / $upcontext['table_count']) * 100);
3837
+			$upcontext['step_progress'] = (int) (($upcontext['cur_table_num'] / $upcontext['table_count']) * 100);
3838 3838
 
3839 3839
 			// Do we need to pause?
3840 3840
 			nextSubstep($substep);
@@ -4071,7 +4071,7 @@  discard block
 block discarded – undo
4071 4071
 				The following files need to be writable to continue the upgrade. Please ensure the Windows permissions are correctly set to allow this:<br>
4072 4072
 				<ul style="margin: 2.5ex; font-family: monospace;">
4073 4073
 					<li>' . implode('</li>
4074
-					<li>', $upcontext['chmod']['files']). '</li>
4074
+					<li>', $upcontext['chmod']['files']) . '</li>
4075 4075
 				</ul>
4076 4076
 			</div>';
4077 4077
 
@@ -4167,7 +4167,7 @@  discard block
 block discarded – undo
4167 4167
 		<title>', $txt['upgrade_upgrade_utility'], '</title>
4168 4168
 		<link rel="stylesheet" href="', $settings['default_theme_url'], '/css/index.css?alp21">
4169 4169
 		<link rel="stylesheet" href="', $settings['default_theme_url'], '/css/install.css?alp21">
4170
-		', $txt['lang_rtl'] == true ? '<link rel="stylesheet" href="' . $settings['default_theme_url'] . '/css/rtl.css?alp21">' : '' , '
4170
+		', $txt['lang_rtl'] == true ? '<link rel="stylesheet" href="' . $settings['default_theme_url'] . '/css/rtl.css?alp21">' : '', '
4171 4171
 		<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js"></script>
4172 4172
 		<script src="', $settings['default_theme_url'], '/scripts/script.js"></script>
4173 4173
 		<script>
@@ -4775,11 +4775,11 @@  discard block
 block discarded – undo
4775 4775
 
4776 4776
 				$totalTime = '';
4777 4777
 				if ($hours > 0)
4778
-					$totalTime .= $hours . ' hour' . ($hours > 1 ? 's':'') . ' ';
4778
+					$totalTime .= $hours . ' hour' . ($hours > 1 ? 's' : '') . ' ';
4779 4779
 				if ($minutes > 0)
4780
-					$totalTime .= $minutes . ' minute' . ($minutes > 1 ? 's':'') . ' ';
4780
+					$totalTime .= $minutes . ' minute' . ($minutes > 1 ? 's' : '') . ' ';
4781 4781
 				if ($seconds > 0)
4782
-					$totalTime .= $seconds . ' second' . ($seconds > 1 ? 's':'') . ' ';
4782
+					$totalTime .= $seconds . ' second' . ($seconds > 1 ? 's' : '') . ' ';
4783 4783
 			}
4784 4784
 
4785 4785
 			if ($is_debug && !empty($totalTime))
@@ -4812,11 +4812,11 @@  discard block
 block discarded – undo
4812 4812
 
4813 4813
 				$totalTime = '';
4814 4814
 				if ($hours > 0)
4815
-					$totalTime .= $hours . ' hour' . ($hours > 1 ? 's':'') . ' ';
4815
+					$totalTime .= $hours . ' hour' . ($hours > 1 ? 's' : '') . ' ';
4816 4816
 				if ($minutes > 0)
4817
-					$totalTime .= $minutes . ' minute' . ($minutes > 1 ? 's':'') . ' ';
4817
+					$totalTime .= $minutes . ' minute' . ($minutes > 1 ? 's' : '') . ' ';
4818 4818
 				if ($seconds > 0)
4819
-					$totalTime .= $seconds . ' second' . ($seconds > 1 ? 's':'') . ' ';
4819
+					$totalTime .= $seconds . ' second' . ($seconds > 1 ? 's' : '') . ' ';
4820 4820
 			}
4821 4821
 
4822 4822
 			echo '
@@ -5543,11 +5543,11 @@  discard block
 block discarded – undo
5543 5543
 	{
5544 5544
 		$totalTime = '';
5545 5545
 		if ($hours > 0)
5546
-			$totalTime .= $hours . ' hour' . ($hours > 1 ? 's':'') . ' ';
5546
+			$totalTime .= $hours . ' hour' . ($hours > 1 ? 's' : '') . ' ';
5547 5547
 		if ($minutes > 0)
5548
-			$totalTime .= $minutes . ' minute' . ($minutes > 1 ? 's':'') . ' ';
5548
+			$totalTime .= $minutes . ' minute' . ($minutes > 1 ? 's' : '') . ' ';
5549 5549
 		if ($seconds > 0)
5550
-			$totalTime .= $seconds . ' second' . ($seconds > 1 ? 's':'') . ' ';
5550
+			$totalTime .= $seconds . ' second' . ($seconds > 1 ? 's' : '') . ' ';
5551 5551
 	}
5552 5552
 
5553 5553
 	if ($is_debug && !empty($totalTime))
Please login to merge, or discard this patch.
other/install.php 1 patch
Spacing   +8 added lines, -10 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
 		'utf8_default' => true,
63 63
 		'utf8_required' => true,
64 64
 		'alter_support' => true,
65
-		'validate_prefix' => function(&$value){
65
+		'validate_prefix' => function(&$value) {
66 66
 			$value = preg_replace('~[^A-Za-z0-9_\$]~', '', $value);
67 67
 			return true;
68 68
 		},
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
 		'utf8_support' => true,
80 80
 		'utf8_version' => '8.0',
81 81
 		'utf8_version_check' => '$request = pg_query(\'SELECT version()\'); list ($version) = pg_fetch_row($request); list($pgl, $version) = explode(" ", $version); return $version;',
82
-		'validate_prefix' => function(&$value){
82
+		'validate_prefix' => function(&$value) {
83 83
 			$value = preg_replace('~[^A-Za-z0-9_\$]~', '', $value);
84 84
 
85 85
 			// Is it reserved?
@@ -741,7 +741,7 @@  discard block
 block discarded – undo
741 741
 	if (isset($_POST['db_user']))
742 742
 	{
743 743
 		$incontext['db']['user'] = $_POST['db_user'];
744
-		$incontext['db']['name'] =  $_POST['db_name'];
744
+		$incontext['db']['name'] = $_POST['db_name'];
745 745
 		$incontext['db']['server'] = $_POST['db_server'];
746 746
 		$incontext['db']['prefix'] = $_POST['db_prefix'];
747 747
 
@@ -1144,7 +1144,7 @@  discard block
 block discarded – undo
1144 1144
 		if ($smcFunc['db_query']('', $current_statement, array('security_override' => true, 'db_error_skip' => true), $db_connection) === false)
1145 1145
 		{
1146 1146
 			// Use the appropriate function based on the DB type
1147
-			if ($db_type == 'mysql' || $db_type =='mysqli')
1147
+			if ($db_type == 'mysql' || $db_type == 'mysqli')
1148 1148
 				$db_errorno = $db_type . '_errno';
1149 1149
 
1150 1150
 			// Error 1050: Table already exists!
@@ -1333,8 +1333,7 @@  discard block
 block discarded – undo
1333 1333
 	require_once($sourcedir . '/Subs.php');
1334 1334
 
1335 1335
 	// We need this to properly hash the password for Admin
1336
-	$smcFunc['strtolower'] = $db_character_set != 'utf8' && $txt['lang_character_set'] != 'UTF-8' ? 'strtolower' :
1337
-		function($string){
1336
+	$smcFunc['strtolower'] = $db_character_set != 'utf8' && $txt['lang_character_set'] != 'UTF-8' ? 'strtolower' : function($string) {
1338 1337
 			global $sourcedir;
1339 1338
 			if (function_exists('mb_strtolower'))
1340 1339
 				return mb_strtolower($string, 'UTF-8');
@@ -1598,8 +1597,7 @@  discard block
 block discarded – undo
1598 1597
 	updateStats('topic');
1599 1598
 
1600 1599
 	// This function is needed to do the updateStats('subject') call.
1601
-	$smcFunc['strtolower'] = $db_character_set != 'utf8' && $txt['lang_character_set'] != 'UTF-8' ? 'strtolower' :
1602
-		function($string){
1600
+	$smcFunc['strtolower'] = $db_character_set != 'utf8' && $txt['lang_character_set'] != 'UTF-8' ? 'strtolower' : function($string) {
1603 1601
 			global $sourcedir;
1604 1602
 			if (function_exists('mb_strtolower'))
1605 1603
 				return mb_strtolower($string, 'UTF-8');
@@ -1627,7 +1625,7 @@  discard block
 block discarded – undo
1627 1625
 	// Sanity check that they loaded earlier!
1628 1626
 	if (isset($modSettings['recycle_board']))
1629 1627
 	{
1630
-		$forum_version = $current_smf_version;  // The variable is usually defined in index.php so lets just use our variable to do it for us.
1628
+		$forum_version = $current_smf_version; // The variable is usually defined in index.php so lets just use our variable to do it for us.
1631 1629
 		scheduled_fetchSMfiles(); // Now go get those files!
1632 1630
 
1633 1631
 		// We've just installed!
@@ -1801,7 +1799,7 @@  discard block
 block discarded – undo
1801 1799
 		<title>', $txt['smf_installer'], '</title>
1802 1800
 		<link rel="stylesheet" href="Themes/default/css/index.css?alp21">
1803 1801
 		<link rel="stylesheet" href="Themes/default/css/install.css?alp21">
1804
-		', $txt['lang_rtl'] == true ? '<link rel="stylesheet" href="Themes/default/css/rtl.css?alp21">' : '' , '
1802
+		', $txt['lang_rtl'] == true ? '<link rel="stylesheet" href="Themes/default/css/rtl.css?alp21">' : '', '
1805 1803
 
1806 1804
 		<script src="Themes/default/scripts/jquery-2.1.3.min.js"></script>
1807 1805
 		<script src="Themes/default/scripts/script.js"></script>
Please login to merge, or discard this patch.