Completed
Pull Request — master (#505)
by Dat
06:14 queued 03:47
created
users.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -106,7 +106,7 @@  discard block
 block discarded – undo
106 106
 	$user->approve();
107 107
 
108 108
 	BootstrapSkin::displayAlertBox(
109
-		"Approved user " . htmlentities($user->getUsername(), ENT_COMPAT, 'UTF-8'), 
109
+		"Approved user ".htmlentities($user->getUsername(), ENT_COMPAT, 'UTF-8'), 
110 110
 		"alert-info", 
111 111
 		"", 
112 112
 		false);
@@ -115,7 +115,7 @@  discard block
 block discarded – undo
115 115
 
116 116
 	$headers = 'From: [email protected]';
117 117
 	// TODO: move to template?
118
-	mail($user->getEmail(), "ACC Account Approved", "Dear " . $user->getOnWikiName() . ",\nYour account " . $user->getUsername() . " has been approved by " . User::getCurrent()->getUsername() . ". To login please go to $baseurl/acc.php.\nPlease note that if you cannot login immediately, we may be updating your identification information in the system.  Please let us know if you continue to have issues if you cannot login after 12 hours pass from the time you receive this approval.\n- The English Wikipedia Account Creation Team", $headers);
118
+	mail($user->getEmail(), "ACC Account Approved", "Dear ".$user->getOnWikiName().",\nYour account ".$user->getUsername()." has been approved by ".User::getCurrent()->getUsername().". To login please go to $baseurl/acc.php.\nPlease note that if you cannot login immediately, we may be updating your identification information in the system.  Please let us know if you continue to have issues if you cannot login after 12 hours pass from the time you receive this approval.\n- The English Wikipedia Account Creation Team", $headers);
119 119
 	BootstrapSkin::displayInternalFooter();
120 120
 	die();
121 121
 }
@@ -159,7 +159,7 @@  discard block
 block discarded – undo
159 159
 		$user->demote($_POST['reason']);
160 160
 
161 161
 		BootstrapSkin::displayAlertBox( 
162
-			"Changed " . htmlentities($user->getUsername(), ENT_COMPAT, 'UTF-8') . "'s access to 'User'", 
162
+			"Changed ".htmlentities($user->getUsername(), ENT_COMPAT, 'UTF-8')."'s access to 'User'", 
163 163
 			"alert-info", 
164 164
 			"", 
165 165
 			false);
@@ -169,7 +169,7 @@  discard block
 block discarded – undo
169 169
 		$headers = 'From: [email protected]';
170 170
         
171 171
 		// TODO: move to template?
172
-		mail($user->getEmail(), "ACC Account Demoted", "Dear " . $user->getOnWikiName() . ",\nYour account " . $user->getUsername() . " has been demoted by " . User::getCurrent()->getUsername() . " because " . User::getCurrent()->getUsername() . ". To contest this demotion please email [email protected].\n- The English Wikipedia Account Creation Team", $headers);
172
+		mail($user->getEmail(), "ACC Account Demoted", "Dear ".$user->getOnWikiName().",\nYour account ".$user->getUsername()." has been demoted by ".User::getCurrent()->getUsername()." because ".User::getCurrent()->getUsername().". To contest this demotion please email [email protected].\n- The English Wikipedia Account Creation Team", $headers);
173 173
 		BootstrapSkin::displayInternalFooter();
174 174
 		die();
175 175
 	}
@@ -213,7 +213,7 @@  discard block
 block discarded – undo
213 213
 
214 214
 		Notification::userSuspended($user, $_POST['reason']);
215 215
 		BootstrapSkin::displayAlertBox(
216
-			"Suspended user " . htmlentities($user->getUsername(), ENT_COMPAT, 'UTF-8'), 
216
+			"Suspended user ".htmlentities($user->getUsername(), ENT_COMPAT, 'UTF-8'), 
217 217
 			"alert-info", 
218 218
 			"", 
219 219
 			false);
@@ -221,7 +221,7 @@  discard block
 block discarded – undo
221 221
 		$headers = 'From: [email protected]';
222 222
         
223 223
 		// TODO: move to template?
224
-		mail($user->getEmail(), "ACC Account Suspended", "Dear " . $user->getOnWikiName() . ",\nYour account " . $user->getUsername() . " has been suspended by " . User::getCurrent()->getUsername() . " because " . $_POST['reason'] . ". To contest this suspension please email [email protected].\n- The English Wikipedia Account Creation Team", $headers);
224
+		mail($user->getEmail(), "ACC Account Suspended", "Dear ".$user->getOnWikiName().",\nYour account ".$user->getUsername()." has been suspended by ".User::getCurrent()->getUsername()." because ".$_POST['reason'].". To contest this suspension please email [email protected].\n- The English Wikipedia Account Creation Team", $headers);
225 225
 		BootstrapSkin::displayInternalFooter();
226 226
 		die();
227 227
 	}
@@ -257,7 +257,7 @@  discard block
 block discarded – undo
257 257
 	Notification::userPromoted($user);
258 258
 
259 259
 	BootstrapSkin::displayAlertBox(
260
-		htmlentities($user->getUsername(), ENT_COMPAT, 'UTF-8') . " promoted to 'Admin'", 
260
+		htmlentities($user->getUsername(), ENT_COMPAT, 'UTF-8')." promoted to 'Admin'", 
261 261
 		"alert-info", 
262 262
 		"", 
263 263
 		false);
@@ -265,7 +265,7 @@  discard block
 block discarded – undo
265 265
 	$headers = 'From: [email protected]';
266 266
     
267 267
 	// TODO: move to template?
268
-	mail($user->getEmail(), "ACC Account Promoted", "Dear " . $user->getOnWikiName() . ",\nYour account " . $user->getUsername() . " has been promted to admin status by " . User::getCurrent()->getUsername() . ".\n- The English Wikipedia Account Creation Team", $headers);
268
+	mail($user->getEmail(), "ACC Account Promoted", "Dear ".$user->getOnWikiName().",\nYour account ".$user->getUsername()." has been promted to admin status by ".User::getCurrent()->getUsername().".\n- The English Wikipedia Account Creation Team", $headers);
269 269
 	die();
270 270
 }
271 271
 
@@ -308,7 +308,7 @@  discard block
 block discarded – undo
308 308
 		Notification::userDeclined($user, $_POST['reason']);
309 309
 
310 310
 		BootstrapSkin::displayAlertBox(
311
-			"Declined user " . htmlentities($user->getUsername(), ENT_COMPAT, 'UTF-8'), 
311
+			"Declined user ".htmlentities($user->getUsername(), ENT_COMPAT, 'UTF-8'), 
312 312
 			"alert-info", 
313 313
 			"", 
314 314
 			false);
@@ -316,7 +316,7 @@  discard block
 block discarded – undo
316 316
 		$headers = 'From: [email protected]';
317 317
         
318 318
 		// TODO: move to template?
319
-		mail($user->getEmail(), "ACC Account Declined", "Dear " . $user->getOnWikiName() . ",\nYour account " . $user->getUsername() . " has been declined access to the account creation tool by " . User::getCurrent()->getUsername() . " because " . $_POST['reason'] . ". For more infomation please email [email protected].\n- The English Wikipedia Account Creation Team", $headers);
319
+		mail($user->getEmail(), "ACC Account Declined", "Dear ".$user->getOnWikiName().",\nYour account ".$user->getUsername()." has been declined access to the account creation tool by ".User::getCurrent()->getUsername()." because ".$_POST['reason'].". For more infomation please email [email protected].\n- The English Wikipedia Account Creation Team", $headers);
320 320
 		BootstrapSkin::displayInternalFooter();
321 321
 		die();
322 322
 	}
Please login to merge, or discard this patch.
config.inc.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -138,7 +138,7 @@  discard block
 block discarded – undo
138 138
 
139 139
 $BUbasefile = "backup"; // The basefile's name.
140 140
 $BUdir = "/home/project/a/c/c/acc/backups"; // The directory where backups should be stored.
141
-$BUmonthdir = $BUdir . "/monthly"; // The directory where monthly backups should be stored.
141
+$BUmonthdir = $BUdir."/monthly"; // The directory where monthly backups should be stored.
142 142
 $BUdumper = "/opt/ts/mysql/5.1/bin/mysqldump --defaults-file=~/.my.cnf p_acc_live"; // Add parameters here if they are needed.
143 143
 $BUgzip = "/usr/bin/gzip"; // Add the gzip parameters here if needed.
144 144
 $BUtar = "/bin/tar -cvf"; // Add the tar parameters here if needed.
@@ -276,19 +276,19 @@  discard block
 block discarded – undo
276 276
 
277 277
 $cDatabaseConfig = array(
278 278
 	"acc" => array(
279
-		"dsrcname" => "mysql:host=" . $toolserver_host . ";dbname=" . $toolserver_database,
279
+		"dsrcname" => "mysql:host=".$toolserver_host.";dbname=".$toolserver_database,
280 280
 		"username" => $toolserver_username,
281 281
 		"password" => $toolserver_password,
282 282
 		"options"  => array(),
283 283
 	),
284 284
 	"wikipedia" => array(
285
-		"dsrcname" => "mysql:host=" . $antispoof_host . ";dbname=" . $antispoof_db,
285
+		"dsrcname" => "mysql:host=".$antispoof_host.";dbname=".$antispoof_db,
286 286
 		"username" => $toolserver_username,
287 287
 		"password" => $toolserver_password,
288 288
 		"options"  => array(),
289 289
 	),
290 290
 	"notifications" => array(
291
-		"dsrcname" => "mysql:host=" . $toolserver_notification_dbhost . ";dbname=" . $toolserver_notification_database,
291
+		"dsrcname" => "mysql:host=".$toolserver_notification_dbhost.";dbname=".$toolserver_notification_database,
292 292
 		"username" => $notifications_username,
293 293
 		"password" => $notifications_password,
294 294
 		"options"  => array(PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES utf8mb4'),
@@ -311,11 +311,11 @@  discard block
 block discarded – undo
311 311
 	"openssl", // email confirmation hash gen, oauth stuff
312 312
 	) as $x) {if (!extension_loaded($x)) {die("extension $x is required."); }}
313 313
 
314
-require_once($filepath . "includes/AutoLoader.php");
314
+require_once($filepath."includes/AutoLoader.php");
315 315
 
316 316
 spl_autoload_register("AutoLoader::load");
317 317
 
318 318
 // Extra includes which are just plain awkward wherever they are.
319
-require_once($filepath . 'oauth/OAuthUtility.php');
320
-require_once($filepath . 'lib/mediawiki-extensions-OAuth/lib/OAuth.php');
321
-require_once($filepath . 'lib/mediawiki-extensions-OAuth/lib/JWT.php');
319
+require_once($filepath.'oauth/OAuthUtility.php');
320
+require_once($filepath.'lib/mediawiki-extensions-OAuth/lib/OAuth.php');
321
+require_once($filepath.'lib/mediawiki-extensions-OAuth/lib/JWT.php');
Please login to merge, or discard this patch.
includes/statistics/StatsIdUsers.php 1 patch
Indentation   +30 added lines, -30 removed lines patch added patch discarded remove patch
@@ -14,31 +14,31 @@  discard block
 block discarded – undo
14 14
 
15 15
 class StatsIdUsers extends StatisticsPage
16 16
 {
17
-    protected function execute()
18
-    {
19
-        return $this->getUserList();
20
-    }
17
+	protected function execute()
18
+	{
19
+		return $this->getUserList();
20
+	}
21 21
 
22
-    public function getPageTitle()
23
-    {
24
-        return "User identification status";
25
-    }
22
+	public function getPageTitle()
23
+	{
24
+		return "User identification status";
25
+	}
26 26
 
27
-    public function getPageName()
28
-    {
29
-        return "IdUsers";
30
-    }
27
+	public function getPageName()
28
+	{
29
+		return "IdUsers";
30
+	}
31 31
 
32
-    public function isProtected()
33
-    {
34
-        return true;
35
-    }
32
+	public function isProtected()
33
+	{
34
+		return true;
35
+	}
36 36
 
37
-    private function getUserList()
38
-    {
39
-        global $currentIdentificationVersion, $forceIdentification;
37
+	private function getUserList()
38
+	{
39
+		global $currentIdentificationVersion, $forceIdentification;
40 40
 
41
-        $query = <<<SQL
41
+		$query = <<<SQL
42 42
 select username, status, checkuser, identified, case 
43 43
     when coalesce(identified, 0) = 0 then 'Not identified'
44 44
     when identified < ${forceIdentification} then 'Expired'
@@ -51,16 +51,16 @@  discard block
 block discarded – undo
51 51
 order by username;
52 52
 SQL;
53 53
 
54
-        $qb = new QueryBrowser();
55
-        $qb->rowFetchMode = PDO::FETCH_NUM;
56
-        $qb->overrideTableTitles = array("User name", "Access level", "Checkuser?", "Version", "Identification status");
57
-        $r = $qb->executeQueryToTable($query);
54
+		$qb = new QueryBrowser();
55
+		$qb->rowFetchMode = PDO::FETCH_NUM;
56
+		$qb->overrideTableTitles = array("User name", "Access level", "Checkuser?", "Version", "Identification status");
57
+		$r = $qb->executeQueryToTable($query);
58 58
 
59
-        return $r;
60
-    }
59
+		return $r;
60
+	}
61 61
 
62
-    public function requiresWikiDatabase()
63
-    {
64
-        return false;
65
-    }
62
+	public function requiresWikiDatabase()
63
+	{
64
+		return false;
65
+	}
66 66
 }
Please login to merge, or discard this patch.