Test Failed
Push — main ( e57cdf...cc1148 )
by chief
57s queued 13s
created
web/public/s/mod/header.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -1,8 +1,8 @@  discard block
 block discarded – undo
1 1
 <?php
2
-	if(isset($_SESSION['siteusername'])) {
2
+	if (isset($_SESSION['siteusername'])) {
3 3
         $stmt = $__db->prepare("UPDATE users SET ip = :ip WHERE username = :username");
4 4
         $stmt->bindParam(":username", $_SESSION['siteusername']);
5
-		$stmt->bindParam(":ip",       $_SERVER["HTTP_CF_CONNECTING_IP"]);
5
+		$stmt->bindParam(":ip", $_SERVER["HTTP_CF_CONNECTING_IP"]);
6 6
         $stmt->execute();
7 7
 	}
8 8
 ?>
@@ -11,7 +11,7 @@  discard block
 block discarded – undo
11 11
 	<a id="logo-container" href="/" title="SubRocks home">
12 12
 	<img id="logo" src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="SubRocks home">
13 13
 	</a>
14
-	<?php if(!isset($_SESSION['siteusername'])) { ?>
14
+	<?php if (!isset($_SESSION['siteusername'])) { ?>
15 15
 	<div id="yt-masthead-signin">
16 16
 		<div id="masthead-user-display"><span id="masthead-user-wrapper"><button href="/sign_in" type="button" id="masthead-user-button" onclick=";window.location.href=this.getAttribute('href');return false;" class=" yt-uix-button yt-uix-button-text" role="button"><span class="yt-uix-button-content">  <span id="masthead-user-image">
17 17
 			<span class="clip">
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
 			<div id="masthead-user-bar">
30 30
 				<div id="masthead-user">
31 31
 					<span id="masthead-gaia-user-expander" class="masthead-user-menu-expander masthead-expander" onclick="yt.www.masthead.toggleExpandedMasthead()"><span id="masthead-gaia-user-wrapper" class="yt-rounded" tabindex="0"><?php echo htmlspecialchars($_SESSION['siteusername']); ?></span></span>
32
-							<?php if($__user_h->fetch_unread_pms($_SESSION['siteusername']) != 0) { ?>
32
+							<?php if ($__user_h->fetch_unread_pms($_SESSION['siteusername']) != 0) { ?>
33 33
 							<button type="button" onclick=";window.location.href=this.getAttribute('href');return false;" href="/inbox/" class="sb-button sb-notif-on yt-uix-button" id="sb-button-notify" role="button"><span class="yt-uix-button-content"><?php echo $__user_h->fetch_unread_pms($_SESSION['siteusername']); ?></span></button>
34 34
 					<?php } else { ?>
35 35
 							<button type="button" onclick=";window.location.href=this.getAttribute('href');return false;" href="/inbox/" class="sb-button sb-notif-off yt-uix-button" id="sb-button-notify" role="button"><span class="yt-uix-button-content"><?php echo $__user_h->fetch_unread_pms($_SESSION['siteusername']); ?></span></button>
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
 	
53 53
 	</div>
54 54
 	
55
-<?php if(isset($_SESSION['siteusername'])) { ?>
55
+<?php if (isset($_SESSION['siteusername'])) { ?>
56 56
 <div id="masthead-expanded" class="hid" style="display: none;">
57 57
 	<div id="masthead-expanded-container" class="with-sandbar">
58 58
 	<div class="yt-uix-slider yt-rounded" id="watch-channel-discoverbox" data-slider-slide-selected="3" data-slider-slides="4"
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
                     $stmt = $__db->prepare("SELECT * FROM videos WHERE author = :username ORDER BY id DESC LIMIT 20");
74 74
                     $stmt->bindParam(":username", $_SESSION['siteusername']);
75 75
                     $stmt->execute();
76
-                    while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { 
76
+                    while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { 
77 77
                         $video['age'] = $__time_h->time_elapsed_string($video['publish']);		
78 78
                         $video['duration'] = $__time_h->timestamp($video['duration']);
79 79
                         $video['views'] = $__video_h->fetch_video_views($video['rid']);
@@ -216,7 +216,7 @@  discard block
 block discarded – undo
216 216
 	</div>
217 217
 <?php } ?>
218 218
 <div id="alerts">
219
-	<?php if(isset($error['status'])) { ?>
219
+	<?php if (isset($error['status'])) { ?>
220 220
 		<div id="masthead_child_div"><div class="yt-alert yt-alert-default yt-alert-error  yt-alert-player">  <div class="yt-alert-icon">
221 221
 			<img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" class="icon master-sprite" alt="Alert icon">
222 222
 		</div>
@@ -226,7 +226,7 @@  discard block
 block discarded – undo
226 226
 			</div>
227 227
 		</div></div></div>
228 228
 	<?php } ?>
229
-	<?php if(isset($_GET['error'])) { ?>
229
+	<?php if (isset($_GET['error'])) { ?>
230 230
 		<div id="masthead_child_div"><div class="yt-alert yt-alert-default yt-alert-error ">  <div class="yt-alert-icon">
231 231
 			<img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" class="icon master-sprite" alt="Alert icon">
232 232
 		</div>
@@ -236,7 +236,7 @@  discard block
 block discarded – undo
236 236
 			</div>
237 237
 		</div></div></div>
238 238
 	<?php } ?>
239
-	<?php if(isset($_GET['success'])) { ?>
239
+	<?php if (isset($_GET['success'])) { ?>
240 240
 		<div id="masthead_child_div"><div class="yt-alert yt-alert-default yt-alert-success ">  <div class="yt-alert-icon">
241 241
 			<img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" class="icon master-sprite" alt="Alert icon">
242 242
 		</div>
@@ -246,7 +246,7 @@  discard block
 block discarded – undo
246 246
 			</div>
247 247
 		</div></div></div>
248 248
 	<?php } ?>
249
-	<?php if(isset($_SESSION['error'])) { ?>
249
+	<?php if (isset($_SESSION['error'])) { ?>
250 250
 		<div id="masthead_child_div"><div class="yt-alert yt-alert-default yt-alert-error">  <div class="yt-alert-icon">
251 251
 			<img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" class="icon master-sprite" alt="Alert icon">
252 252
 		</div>
Please login to merge, or discard this patch.