Completed
Pull Request — master (#218)
by Christopher
67:05 queued 62:34
created
public/plugins/datatables/extensions/Scroller/examples/data/ssp.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -29,11 +29,11 @@
 block discarded – undo
29 29
 // parameter represents the DataTables column identifier. In this case simple
30 30
 // indexes
31 31
 $columns = [
32
-    ['db' => 'id',         'dt' => 0],
33
-    ['db' => 'firstname',  'dt' => 1],
34
-    ['db' => 'surname',    'dt' => 2],
35
-    ['db' => 'zip',        'dt' => 3],
36
-    ['db' => 'country',    'dt' => 4],
32
+    ['db' => 'id', 'dt' => 0],
33
+    ['db' => 'firstname', 'dt' => 1],
34
+    ['db' => 'surname', 'dt' => 2],
35
+    ['db' => 'zip', 'dt' => 3],
36
+    ['db' => 'country', 'dt' => 4],
37 37
 ];
38 38
 
39 39
 // SQL server connection information
Please login to merge, or discard this patch.
public/old/swaps.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
 // ensure user is allowed to see page
40 40
 
41 41
 if (!isAdmin() && $queryStringUser != $sessionUserId) {
42
-    header('Location: swaps.php?user='.$sessionUserId);
42
+    header('Location: swaps.php?user=' . $sessionUserId);
43 43
 }
44 44
 
45 45
 // fetch swaps
@@ -90,11 +90,11 @@  discard block
 block discarded – undo
90 90
               <p>
91 91
                 <strong>
92 92
                   <s class="text-red">
93
-                    <?php echo $swap->getOldUserRole()->getUser()->getFirstName().' '.$swap->getOldUserRole()->getUser()->getLastName() ?> (<?php echo $swap->getOldUserRole()->getRole()->getName() ?>)
93
+                    <?php echo $swap->getOldUserRole()->getUser()->getFirstName() . ' ' . $swap->getOldUserRole()->getUser()->getLastName() ?> (<?php echo $swap->getOldUserRole()->getRole()->getName() ?>)
94 94
                   </s>
95 95
                   &#8594;
96 96
                   <span class="text-green">
97
-                    <?php echo $swap->getNewUserRole()->getUser()->getFirstName().' '.$swap->getNewUserRole()->getUser()->getLastName() ?> (<?php echo $swap->getNewUserRole()->getRole()->getName() ?>)
97
+                    <?php echo $swap->getNewUserRole()->getUser()->getFirstName() . ' ' . $swap->getNewUserRole()->getUser()->getLastName() ?> (<?php echo $swap->getNewUserRole()->getRole()->getName() ?>)
98 98
                   </span>
99 99
                 </strong>
100 100
               </p>
Please login to merge, or discard this patch.
public/old/subTypes.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -53,8 +53,8 @@
 block discarded – undo
53 53
     }
54 54
 
55 55
     // After we have inserted the data, we want to head back to the main users page
56
-     header('Location: subTypes.php'); // Move to the home page of the admin section
57
-      exit;
56
+        header('Location: subTypes.php'); // Move to the home page of the admin section
57
+        exit;
58 58
 }
59 59
 include 'includes/header.php';
60 60
 ?>
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@  discard block
 block discarded – undo
16 16
     exit;
17 17
 }
18 18
 if (!isAdmin()) {
19
-    header('Location: error.php?no=100&page='.basename($_SERVER['SCRIPT_FILENAME']));
19
+    header('Location: error.php?no=100&page=' . basename($_SERVER['SCRIPT_FILENAME']));
20 20
     exit;
21 21
 }
22 22
 
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
 
40 40
         $sql = ("INSERT INTO eventSubTypes (name, description) VALUES ('$name', '$description')");
41 41
         if (!mysqli_query(db(), $sql)) {
42
-            exit('Error: '.mysqli_error(db()));
42
+            exit('Error: ' . mysqli_error(db()));
43 43
         }
44 44
     } else {
45 45
         // Otherwise we are dealing with edits, not new stuff
@@ -90,10 +90,10 @@  discard block
 block discarded – undo
90 90
     $result = mysqli_query(db(), $sql) or exit(mysqli_error(db()));
91 91
 
92 92
     while ($row = mysqli_fetch_array($result, MYSQLI_ASSOC)) {
93
-        echo '<input type="hidden" name="formindex[]" value="'.$row['id'].'" />';
94
-        echo "<input name='name[]' value='".$row['name']."' />";
93
+        echo '<input type="hidden" name="formindex[]" value="' . $row['id'] . '" />';
94
+        echo "<input name='name[]' value='" . $row['name'] . "' />";
95 95
 
96
-        echo " <a href='subTypes.php?method=remove&subType=".$row['id']."'><i class='fa fa-times'></i></a><br />";
96
+        echo " <a href='subTypes.php?method=remove&subType=" . $row['id'] . "'><i class='fa fa-times'></i></a><br />";
97 97
     } ?>
98 98
    </div><!-- /.box-body -->
99 99
    <div class="box-footer">
Please login to merge, or discard this patch.
public/old/emailGroup.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@
 block discarded – undo
53 53
         $statusMessage = 'Sent successfully';
54 54
     } else {
55 55
         foreach ($sent as $errorMessage) {
56
-            $statusMessage .= '<p>'.$errorMessage.'</p>';
56
+            $statusMessage .= '<p>' . $errorMessage . '</p>';
57 57
         }
58 58
     }
59 59
 
Please login to merge, or discard this patch.
public/old/editRole.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@
 block discarded – undo
34 34
 }
35 35
 
36 36
 if (!isAdmin()) {
37
-    header('Location: error.php?no=100&page='.basename($_SERVER['SCRIPT_FILENAME']));
37
+    header('Location: error.php?no=100&page=' . basename($_SERVER['SCRIPT_FILENAME']));
38 38
     exit;
39 39
 }
40 40
 
Please login to merge, or discard this patch.
public/old/editeventtype.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@
 block discarded – undo
14 14
     exit;
15 15
 }
16 16
 if (!isAdmin()) {
17
-    header('Location: error.php?no=100&page='.basename($_SERVER['SCRIPT_FILENAME']));
17
+    header('Location: error.php?no=100&page=' . basename($_SERVER['SCRIPT_FILENAME']));
18 18
     exit;
19 19
 }
20 20
 
Please login to merge, or discard this patch.
public/old/pendingAccounts.php 2 patches
Indentation   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -30,24 +30,24 @@
 block discarded – undo
30 30
     switch ($_POST['action']) {
31 31
     case 'approve':
32 32
       $userId = approvePendingUser($id);
33
-      mailNewUser($userId);
34
-      header('Location: addUser.php?action=edit&user='.$userId);
35
-      break;
33
+        mailNewUser($userId);
34
+        header('Location: addUser.php?action=edit&user='.$userId);
35
+        break;
36 36
     case 'merge':
37 37
       $existingUserId = $_POST['existingUser'];
38
-      $existingUserId = filter_var($existingUserId, FILTER_SANITIZE_NUMBER_INT);
39
-      mergePendingUserWithUserId($id, $existingUserId);
40
-      mailNewUser($existingUserId);
41
-      header('Location: addUser.php?action=edit&user='.$existingUserId);
42
-      break;
38
+        $existingUserId = filter_var($existingUserId, FILTER_SANITIZE_NUMBER_INT);
39
+        mergePendingUserWithUserId($id, $existingUserId);
40
+        mailNewUser($existingUserId);
41
+        header('Location: addUser.php?action=edit&user='.$existingUserId);
42
+        break;
43 43
     case 'decline':
44 44
       declinePendingUser($id);
45
-      break;
45
+        break;
46 46
 
47 47
     default:
48 48
       // code...
49 49
       break;
50
-  }
50
+    }
51 51
 }
52 52
 
53 53
 if (empty($id)) {
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@  discard block
 block discarded – undo
16 16
     exit;
17 17
 }
18 18
 if (!isAdmin()) {
19
-    header('Location: error.php?no=100&page='.basename($_SERVER['SCRIPT_FILENAME']));
19
+    header('Location: error.php?no=100&page=' . basename($_SERVER['SCRIPT_FILENAME']));
20 20
     exit;
21 21
 }
22 22
 
@@ -33,14 +33,14 @@  discard block
 block discarded – undo
33 33
     case 'approve':
34 34
       $userId = approvePendingUser($id);
35 35
       mailNewUser($userId);
36
-      header('Location: addUser.php?action=edit&user='.$userId);
36
+      header('Location: addUser.php?action=edit&user=' . $userId);
37 37
       break;
38 38
     case 'merge':
39 39
       $existingUserId = $_POST['existingUser'];
40 40
       $existingUserId = filter_var($existingUserId, FILTER_SANITIZE_NUMBER_INT);
41 41
       mergePendingUserWithUserId($id, $existingUserId);
42 42
       mailNewUser($existingUserId);
43
-      header('Location: addUser.php?action=edit&user='.$existingUserId);
43
+      header('Location: addUser.php?action=edit&user=' . $existingUserId);
44 44
       break;
45 45
     case 'decline':
46 46
       declinePendingUser($id);
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
 <div class="box box-primary">
93 93
   <div class="box-header">
94 94
     <h2 class="box-title">
95
-      <?php echo $user->approved ? 'Approved' : ($user->declined ? 'Declined' : 'Pending') ?>: <?php echo $user->firstName.' '.$user->lastName ?>
95
+      <?php echo $user->approved ? 'Approved' : ($user->declined ? 'Declined' : 'Pending') ?>: <?php echo $user->firstName . ' ' . $user->lastName ?>
96 96
     </h2>
97 97
   </div>
98 98
   <div class="box-body">
@@ -133,7 +133,7 @@  discard block
 block discarded – undo
133 133
             <?php
134 134
             $users = allUsersNames();
135 135
             foreach ($users as $existingUser) { ?>
136
-            <option value="<?php echo $existingUser->id?>" <?php echo($existingUser->firstName == $user->firstName) && ($existingUser->lastName == $user->lastName) ? "selected='selected'" : '' ?>><?php echo $existingUser->firstName.' '.$existingUser->lastName ?></option>
136
+            <option value="<?php echo $existingUser->id?>" <?php echo($existingUser->firstName == $user->firstName) && ($existingUser->lastName == $user->lastName) ? "selected='selected'" : '' ?>><?php echo $existingUser->firstName . ' ' . $existingUser->lastName ?></option>
137 137
             <?php } ?>
138 138
           </select>
139 139
         </div>
Please login to merge, or discard this patch.
public/old/install.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
 } catch (\Exception $e) {
35 35
 }
36 36
 
37
-$url = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' ? 'https' : 'http').'://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI'];
37
+$url = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' ? 'https' : 'http') . '://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];
38 38
 $url = substr($url, 0, -12); // remove "/install.php" from url
39 39
 
40 40
 if ($_SERVER['REQUEST_METHOD'] == 'POST') {
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
         //exit;
49 49
         $conn->exec($sql);
50 50
     } catch (\Exception $e) {
51
-        echo 'Error (code: '.$e->getCode().') adding tables to database: '.$e->getMessage();
51
+        echo 'Error (code: ' . $e->getCode() . ') adding tables to database: ' . $e->getMessage();
52 52
         exit;
53 53
     }
54 54
 
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
     $lastname = $_POST['lastname'];
59 59
     $lastname = trim(strip_tags($lastname));
60 60
 
61
-    $username = strtolower($firstname).'.'.strtolower($lastname);
61
+    $username = strtolower($firstname) . '.' . strtolower($lastname);
62 62
 
63 63
     $password = $_POST['password'];
64 64
 
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
     try {
83 83
         $user->save();
84 84
     } catch (\Exception $e) {
85
-        echo 'Error (code: '.$e->getCode().') adding user to database: '.$e->getMessage();
85
+        echo 'Error (code: ' . $e->getCode() . ') adding user to database: ' . $e->getMessage();
86 86
         exit;
87 87
     }
88 88
 
@@ -179,7 +179,7 @@  discard block
 block discarded – undo
179 179
 
180 180
     $settings->save();
181 181
 
182
-    header('Location: login.php?username='.$username); // Move to the home page of the admin section
182
+    header('Location: login.php?username=' . $username); // Move to the home page of the admin section
183 183
     exit;
184 184
 }
185 185
 
Please login to merge, or discard this patch.
public/old/includes/errors.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,6 +2,6 @@
 block discarded – undo
2 2
 
3 3
 namespace TechWilk\Rota;
4 4
 
5
-ini_set('display_errors', false);    // set on for development, off for production
5
+ini_set('display_errors', false); // set on for development, off for production
6 6
 ini_set('log_errors', true);
7 7
 error_reporting(E_ALL);
Please login to merge, or discard this patch.