Test Failed
Push — main ( 594560...d41f84 )
by chief
05:05 queued 02:09
created
web/public/watch.php 1 patch
Braces   +11 added lines, -8 removed lines patch added patch discarded remove patch
@@ -15,8 +15,9 @@  discard block
 block discarded – undo
15 15
 <?php $_video = $__video_h->fetch_video_rid($_GET['v']); ?>
16 16
 <?php $_video['comments'] = $__video_h->get_comments_from_video($_video['rid']); ?>
17 17
 <?php
18
-	if($_video['visibility'] == "v" && @$_SESSION['siteusername'] != $_video['author'])
19
-		header("Location: /");
18
+	if($_video['visibility'] == "v" && @$_SESSION['siteusername'] != $_video['author']) {
19
+			header("Location: /");
20
+	}
20 21
 
21 22
 	$__video_h->check_view($_GET['v'], @$_SERVER["HTTP_CF_CONNECTING_IP"]);
22 23
 
@@ -164,11 +165,12 @@  discard block
 block discarded – undo
164 165
 										if($alts != 0) { echo "<span style='font-size:11px;color:grey;'>Alts will pop up below here...</span><br>"; }
165 166
 
166 167
 										while($username = $stmt->fetch(PDO::FETCH_ASSOC)) { 
167
-											if($username['username'] != $_video['author'] && $username['ip'] != "0.0.0.0")
168
-												echo "
168
+											if($username['username'] != $_video['author'] && $username['ip'] != "0.0.0.0") {
169
+																							echo "
169 170
 												  <a style='font-size:10px;' href='/user/" .  htmlspecialchars($username['username']) . "'>" . 
170 171
 													htmlspecialchars($username['username']) 
171 172
 												. "</a><br>";
173
+											}
172 174
 										}
173 175
 									?>
174 176
 									<hr>
@@ -790,10 +792,11 @@  discard block
 block discarded – undo
790 792
 														$stmt->execute();
791 793
 
792 794
 														while($comment = $stmt->fetch(PDO::FETCH_ASSOC)) { 
793
-															if($__video_h->if_comment_liked($comment['id'], $_SESSION['siteusername'], true))
794
-																$comment['liked'] = true;
795
-															else if($__video_h->if_comment_liked($comment['id'], $_SESSION['siteusername'], false))
796
-																$comment['disliked'] = true;
795
+															if($__video_h->if_comment_liked($comment['id'], $_SESSION['siteusername'], true)) {
796
+																															$comment['liked'] = true;
797
+															} else if($__video_h->if_comment_liked($comment['id'], $_SESSION['siteusername'], false)) {
798
+																															$comment['disliked'] = true;
799
+															}
797 800
 																
798 801
 															$comment['likes']  = $__video_h->get_comment_likes($comment['id'], true);
799 802
 															$comment['likes'] -= $__video_h->get_comment_likes($comment['id'], false);
Please login to merge, or discard this patch.