Completed
Pull Request — newinternal (#418)
by Matthew
04:57
created
config.inc.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -130,7 +130,7 @@  discard block
 block discarded – undo
130 130
 
131 131
 $BUbasefile = "backup"; // The basefile's name.
132 132
 $BUdir = "/home/project/a/c/c/acc/backups"; // The directory where backups should be stored.
133
-$BUmonthdir = $BUdir . "/monthly"; // The directory where monthly backups should be stored.
133
+$BUmonthdir = $BUdir."/monthly"; // The directory where monthly backups should be stored.
134 134
 $BUdumper = "/opt/ts/mysql/5.1/bin/mysqldump --defaults-file=~/.my.cnf p_acc_live"; // Add parameters here if they are needed.
135 135
 $BUgzip = "/usr/bin/gzip"; // Add the gzip parameters here if needed.
136 136
 $BUtar = "/bin/tar -cvf"; // Add the tar parameters here if needed.
@@ -253,17 +253,17 @@  discard block
 block discarded – undo
253 253
 
254 254
 $cDatabaseConfig = array(
255 255
     "acc"           => array(
256
-        "dsrcname" => "mysql:host=" . $toolserver_host . ";dbname=" . $toolserver_database,
256
+        "dsrcname" => "mysql:host=".$toolserver_host.";dbname=".$toolserver_database,
257 257
         "username" => $toolserver_username,
258 258
         "password" => $toolserver_password,
259 259
     ),
260 260
     "wikipedia"     => array(
261
-        "dsrcname" => "mysql:host=" . $antispoof_host . ";dbname=" . $antispoof_db,
261
+        "dsrcname" => "mysql:host=".$antispoof_host.";dbname=".$antispoof_db,
262 262
         "username" => $toolserver_username,
263 263
         "password" => $toolserver_password,
264 264
     ),
265 265
     "notifications" => array(
266
-        "dsrcname" => "mysql:host=" . $toolserver_notification_dbhost . ";dbname=" . $toolserver_notification_database,
266
+        "dsrcname" => "mysql:host=".$toolserver_notification_dbhost.";dbname=".$toolserver_notification_database,
267 267
         "username" => $notifications_username,
268 268
         "password" => $notifications_password,
269 269
     ),
@@ -293,13 +293,13 @@  discard block
 block discarded – undo
293 293
 }
294 294
 
295 295
 // Set up the AutoLoader
296
-require_once(__DIR__ . "/includes/AutoLoader.php");
296
+require_once(__DIR__."/includes/AutoLoader.php");
297 297
 spl_autoload_register('Waca\\AutoLoader::load');
298
-require_once(__DIR__ . '/vendor/autoload.php');
298
+require_once(__DIR__.'/vendor/autoload.php');
299 299
 
300 300
 // Extra includes which are just plain awkward wherever they are.
301
-require_once(__DIR__ . '/lib/mediawiki-extensions-OAuth/lib/OAuth.php');
302
-require_once(__DIR__ . '/lib/mediawiki-extensions-OAuth/lib/JWT.php');
301
+require_once(__DIR__.'/lib/mediawiki-extensions-OAuth/lib/OAuth.php');
302
+require_once(__DIR__.'/lib/mediawiki-extensions-OAuth/lib/JWT.php');
303 303
 
304 304
 // Crap that's needed for libraries. >:(
305 305
 /**
Please login to merge, or discard this patch.
includes/Tasks/PageBase.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -212,7 +212,7 @@  discard block
 block discarded – undo
212 212
             $targetScriptName = $currentScriptName;
213 213
         }
214 214
         else {
215
-            $targetScriptName = $this->getSiteConfiguration()->getBaseUrl() . '/' . $script;
215
+            $targetScriptName = $this->getSiteConfiguration()->getBaseUrl().'/'.$script;
216 216
         }
217 217
 
218 218
         $pathInfo = array($targetScriptName);
@@ -226,7 +226,7 @@  discard block
 block discarded – undo
226 226
         $url = implode('/', $pathInfo);
227 227
 
228 228
         if (is_array($parameters) && count($parameters) > 0) {
229
-            $url .= '?' . http_build_query($parameters);
229
+            $url .= '?'.http_build_query($parameters);
230 230
         }
231 231
 
232 232
         $this->redirectUrl($url);
@@ -310,7 +310,7 @@  discard block
 block discarded – undo
310 310
     protected function sendResponseHeaders()
311 311
     {
312 312
         if (headers_sent()) {
313
-            throw new ApplicationLogicException          ('Headers have already been sent! This is likely a bug in the application.');
313
+            throw new ApplicationLogicException('Headers have already been sent! This is likely a bug in the application.');
314 314
         }
315 315
 
316 316
         foreach ($this->headerQueue as $item) {
Please login to merge, or discard this patch.
includes/Tasks/ApiPageBase.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -69,7 +69,7 @@
 block discarded – undo
69 69
             $CORSallowed = $this->getSiteConfiguration()->getCrossOriginResourceSharingHosts();
70 70
 
71 71
             if (in_array($httpOrigin, $CORSallowed)) {
72
-                header("Access-Control-Allow-Origin: " . $httpOrigin);
72
+                header("Access-Control-Allow-Origin: ".$httpOrigin);
73 73
             }
74 74
         }
75 75
 
Please login to merge, or discard this patch.
includes/Pages/PageSearch.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -86,7 +86,7 @@  discard block
 block discarded – undo
86 86
      */
87 87
     private function getNameSearchResults($searchTerm)
88 88
     {
89
-        $padded = '%' . $searchTerm . '%';
89
+        $padded = '%'.$searchTerm.'%';
90 90
 
91 91
         return RequestSearchHelper::get($this->getDatabase())
92 92
             ->byName($padded)
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
             throw new ApplicationLogicException('The search term "@" is not valid for email address searches!');
109 109
         }
110 110
 
111
-        $padded = '%' . $searchTerm . '%';
111
+        $padded = '%'.$searchTerm.'%';
112 112
 
113 113
         return RequestSearchHelper::get($this->getDatabase())
114 114
             ->byEmailAddress($padded)
Please login to merge, or discard this patch.
includes/Pages/PageTeam.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
      */
20 20
     protected function main()
21 21
     {
22
-        $path = $this->getSiteConfiguration()->getFilePath() . '/team.json';
22
+        $path = $this->getSiteConfiguration()->getFilePath().'/team.json';
23 23
         $json = file_get_contents($path);
24 24
 
25 25
         $teamData = json_decode($json, true);
Please login to merge, or discard this patch.
includes/Pages/Statistics/StatsUsers.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@
 block discarded – undo
62 62
         }
63 63
 
64 64
         $safeUsername = htmlentities($user->getUsername(), ENT_COMPAT, 'UTF-8');
65
-        $this->setHtmlTitle($safeUsername . ' :: Users :: Statistics');
65
+        $this->setHtmlTitle($safeUsername.' :: Users :: Statistics');
66 66
 
67 67
         $activitySummary = $database->prepare(<<<SQL
68 68
 SELECT COALESCE(closes.mail_desc, log.action) AS action, COUNT(*) AS count
Please login to merge, or discard this patch.
includes/Pages/PageLogin.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@
 block discarded – undo
36 36
             }
37 37
             else {
38 38
                 // This is the login form, not the request form. We need protection here.
39
-                $this->redirectUrl('https://' . WebRequest::serverName() . WebRequest::requestUri());
39
+                $this->redirectUrl('https://'.WebRequest::serverName().WebRequest::requestUri());
40 40
 
41 41
                 return;
42 42
             }
Please login to merge, or discard this patch.
includes/Pages/RequestAction/PageCloseRequest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -239,11 +239,11 @@
 block discarded – undo
239 239
 
240 240
         $emailSig = $currentUser->getEmailSig();
241 241
         if ($emailSig !== '' || $emailSig !== null) {
242
-            $emailSig = "\n\n" . $emailSig;
242
+            $emailSig = "\n\n".$emailSig;
243 243
         }
244 244
 
245 245
         $subject = "RE: [ACC #{$request->getId()}] English Wikipedia Account Request";
246
-        $content = $mailText . $emailSig;
246
+        $content = $mailText.$emailSig;
247 247
 
248 248
         $helper->sendMail($request->getEmail(), $subject, $content, $headers);
249 249
 
Please login to merge, or discard this patch.
includes/Pages/RequestAction/PageComment.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -48,8 +48,8 @@
 block discarded – undo
48 48
         }
49 49
 
50 50
         //Look for and detect IPv4/IPv6 addresses in comment text, and warn the commenter.
51
-        $ipv4Regex = '/\b' . RegexConstants::IPV4 . '\b/';
52
-        $ipv6Regex = '/\b' . RegexConstants::IPV6 . '\b/';
51
+        $ipv4Regex = '/\b'.RegexConstants::IPV4.'\b/';
52
+        $ipv6Regex = '/\b'.RegexConstants::IPV6.'\b/';
53 53
 
54 54
         $overridePolicy = WebRequest::postBoolean('privpol-check-override');
55 55
 
Please login to merge, or discard this patch.