Failed Conditions
Pull Request — master (#1326)
by Nick
26:02 queued 20:44
created
www/includes/easyparliament/templates/html/scotland/index.php 2 patches
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -11,10 +11,10 @@  discard block
 block discarded – undo
11 11
                 </div>
12 12
                 <div class="row">
13 13
                     <div class="medium-9 columns">
14
-                    <?php if ( count($data['regional']) > 0 ) { ?>
14
+                    <?php if (count($data['regional']) > 0) { ?>
15 15
                         <ul class="homepage-rep-list">
16 16
                         <li>Your Regional MSPs:</li>
17
-                        <?php foreach ( $data['regional'] as $msp ) { ?>
17
+                        <?php foreach ($data['regional'] as $msp) { ?>
18 18
                             <li class="homepage-rep-list__rep"><a href="/msp/?p=<?= $msp['person_id'] ?>"><?= $msp['name'] ?></a></li>
19 19
                         <?php } ?>
20 20
                         </ul>
@@ -57,8 +57,8 @@  discard block
 block discarded – undo
57 57
             <div class="panel panel--flushtop clearfix">
58 58
                 <div class="row nested-row">
59 59
                     <div class="homepage-in-the-news homepage-content-section">
60
-                        <?php if ( $featured ) {
61
-                             include dirname(__FILE__) . "/../homepage/featured.php";
60
+                        <?php if ($featured) {
61
+                             include dirname(__FILE__)."/../homepage/featured.php";
62 62
                         } ?>
63 63
                     </div>
64 64
                     <div class="homepage-create-alert homepage-content-section">
@@ -102,8 +102,8 @@  discard block
 block discarded – undo
102 102
                     <div class="homepage-recently homepage-content-section">
103 103
                         <h2>Recently in Parliament</h2>
104 104
                         <ul class="recently__list"><?php
105
-                            foreach ( $debates['recent'] as $recent ) {
106
-                                include dirname(__FILE__) . '/../homepage/recent-debates.php';
105
+                            foreach ($debates['recent'] as $recent) {
106
+                                include dirname(__FILE__).'/../homepage/recent-debates.php';
107 107
                             }
108 108
                         ?></ul>
109 109
                     </div>
Please login to merge, or discard this patch.
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@
 block discarded – undo
41 41
                 <div class="row nested-row">
42 42
                     <div class="homepage-in-the-news homepage-content-section">
43 43
                         <?php if ( $featured ) {
44
-                             include dirname(__FILE__) . "/../homepage/featured.php";
44
+                                include dirname(__FILE__) . "/../homepage/featured.php";
45 45
                         } ?>
46 46
                     </div>
47 47
                     <div class="homepage-create-alert homepage-content-section">
Please login to merge, or discard this patch.
www/includes/easyparliament/templates/html/hansard_search_video.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -24,28 +24,28 @@
 block discarded – undo
24 24
     foreach ($data['rows'] as $n => $row) {
25 25
         echo '<dt>';
26 26
         if (isset($row['parent']) && count($row['parent']) > 0) {
27
-            echo ('<strong>' . $row['parent']['body'] . '</strong>');
27
+            echo ('<strong>'.$row['parent']['body'].'</strong>');
28 28
         }
29 29
         echo '</dt> <dd>';
30 30
         if (isset($row['speaker']) && count($row['speaker'])) {
31
-            echo "<em>" . ucfirst($row['speaker']['name']) . "</em>: ";
31
+            echo "<em>".ucfirst($row['speaker']['name'])."</em>: ";
32 32
         }
33 33
 
34
-        echo '&#8220;' . $row['extract'] . "&#8221;</dd>\n";
34
+        echo '&#8220;'.$row['extract']."&#8221;</dd>\n";
35 35
         echo '<dd><em><small>This speech is ';
36
-        if ($row['hpos']-$want['hpos']>0) {
37
-            echo ($row['hpos']-$want['hpos']) . ' later than';
36
+        if ($row['hpos'] - $want['hpos'] > 0) {
37
+            echo ($row['hpos'] - $want['hpos']).' later than';
38 38
         } else {
39
-            echo ($want['hpos']-$row['hpos']) . ' earlier than';
39
+            echo ($want['hpos'] - $row['hpos']).' earlier than';
40 40
         }
41 41
         echo ' the one you want &ndash; ';
42
-        if ($row['video_status']&8 || !($row['video_status']&1)) {
42
+        if ($row['video_status'] & 8 || !($row['video_status'] & 1)) {
43 43
             echo ' it doesn\'t have any video';
44
-        } elseif ($row['video_status']&4) {
44
+        } elseif ($row['video_status'] & 4) {
45 45
             echo ' it has already been matched';
46
-        } elseif ($row['video_status']&1) {
46
+        } elseif ($row['video_status'] & 1) {
47 47
             # Only for Commons currently
48
-            echo ' if you prefer, <a target="_top" onclick="t = parent.document[\'video\'].currentTime(); this.href += t;" href="/video/?gid=debate/' . $row['gid'] . '&amp;file=' . $want['file'] . '&amp;start=">switch to matching this speech instead</a>';
48
+            echo ' if you prefer, <a target="_top" onclick="t = parent.document[\'video\'].currentTime(); this.href += t;" href="/video/?gid=debate/'.$row['gid'].'&amp;file='.$want['file'].'&amp;start=">switch to matching this speech instead</a>';
49 49
         }
50 50
         echo '</small></em></dd>';
51 51
     }
Please login to merge, or discard this patch.
www/includes/easyparliament/templates/html/trackbacks.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
 if (count($data) > 0) {
39 39
 
40 40
     if ($info['view'] == 'recent') {
41
-        $title = $info['num'] . ' most recent trackbacks';
41
+        $title = $info['num'].' most recent trackbacks';
42 42
     } else {
43 43
         $title = 'Some sites linking to this page';
44 44
     }
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
         ?>
65 65
         <dt><a href="<?php echo _htmlentities($trackback['url']); ?>"><?php echo _htmlentities($trackback['title']); ?></a></dt>
66 66
         <dd><?php echo _htmlentities($trackback['excerpt']); ?><br>
67
-            <small>At <?php echo _htmlentities($trackback['blog_name']); ?> on <?php echo $date . ' ' . $time; ?></small>
67
+            <small>At <?php echo _htmlentities($trackback['blog_name']); ?> on <?php echo $date.' '.$time; ?></small>
68 68
         </dd>
69 69
 <?php
70 70
 
Please login to merge, or discard this patch.
www/includes/easyparliament/templates/html/divisions/vote.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -113,7 +113,7 @@
 block discarded – undo
113 113
             </div>
114 114
 
115 115
              <ul class="debate-speech__meta debate-speech__links">
116
-             <?php if ( $division['debate_url'] ) { ?>
116
+             <?php if ($division['debate_url']) { ?>
117 117
                   <li class="link-to-speech">
118 118
                       <a class="link debate-speech__meta__link" href="<?= $division['debate_url'] ?>">Show full debate</a>
119 119
                   </li>
Please login to merge, or discard this patch.
www/includes/easyparliament/templates/html/divisions/_vote_list.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -9,10 +9,10 @@
 block discarded – undo
9 9
                     ?>
10 10
                     <ul class="division-list">
11 11
                         <?php foreach ($votes as $vote) {
12
-                          $voter = sprintf('<a href="/mp/?p=%d">%s</a>', $vote['person_id'], $vote['name']);
13
-                          if ($vote['teller']) {
14
-                              $tellers[] = $voter;
15
-                          } else { ?>
12
+                            $voter = sprintf('<a href="/mp/?p=%d">%s</a>', $vote['person_id'], $vote['name']);
13
+                            if ($vote['teller']) {
14
+                                $tellers[] = $voter;
15
+                            } else { ?>
16 16
                             <li><?= $voter ?></li>
17 17
                         <?php
18 18
                             }
Please login to merge, or discard this patch.
www/includes/easyparliament/templates/html/divisions/index.php 2 patches
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -7,9 +7,9 @@  discard block
 block discarded – undo
7 7
           </div>
8 8
           <div class="business-section__primary">
9 9
                <?php
10
-               if ( isset($divisions) && $divisions ) {
11
-                 $current_date = '';
12
-               ?>
10
+                if ( isset($divisions) && $divisions ) {
11
+                    $current_date = '';
12
+                ?>
13 13
                <ul class="business-list">
14 14
                     <?php foreach ($divisions as $division) { ?>
15 15
                     <li id="<?= $division['division_id'] ?>">
@@ -18,7 +18,7 @@  discard block
 block discarded – undo
18 18
                         <h3><?= format_date($division['date'], LONGERDATEFORMAT) ?></h3>
19 19
                         </span>
20 20
                         <?php
21
-                          $current_date = $division['date'];
21
+                            $current_date = $division['date'];
22 22
                         } ?>
23 23
                         <a href="/divisions/<?= $division['division_id'] ?>" class="business-list__title">
24 24
                             <h3><?= $division['division_title'] ?></h3>
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -7,7 +7,7 @@  discard block
 block discarded – undo
7 7
           </div>
8 8
           <div class="business-section__primary">
9 9
                <?php
10
-               if ( isset($divisions) && $divisions ) {
10
+               if (isset($divisions) && $divisions) {
11 11
                  $current_date = '';
12 12
                ?>
13 13
                <ul class="business-list">
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
                             <br>
30 30
                             <span class="business-list__meta">
31 31
                                 <?= $division['summary'] ?>
32
-                                <?= $division['mp_vote'] !== '' ? '. <b>Your MP, ' . $mp_name . ', ' . $division['mp_vote'] . '.</b>': '' ?>
32
+                                <?= $division['mp_vote'] !== '' ? '. <b>Your MP, '.$mp_name.', '.$division['mp_vote'].'.</b>' : '' ?>
33 33
                             </span>
34 34
                         </p>
35 35
                     </li>
Please login to merge, or discard this patch.
www/includes/easyparliament/templates/html/comments_recent.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@  discard block
 block discarded – undo
14 14
 if (isset($data['comments']) && count($data['comments']) > 0) {
15 15
     $title = 'Most recent annotations';
16 16
     if (isset($data['full_name'])) {
17
-        $title .= ' on things by ' . $data['full_name'];
17
+        $title .= ' on things by '.$data['full_name'];
18 18
     }
19 19
     $PAGE->block_start(array('id'=>'recentcomments', 'title'=>$title));
20 20
 
@@ -33,11 +33,11 @@  discard block
 block discarded – undo
33 33
         $date = format_date($date, SHORTDATEFORMAT);
34 34
         $time = format_time($time, TIMEFORMAT);
35 35
 
36
-        $count = $n+1;
36
+        $count = $n + 1;
37 37
 
38 38
         $USERURL->insert(array('u'=>$comment['user_id']));
39 39
 
40
-        ?><a name="c<?php echo $count; ?>"></a><strong><?php echo _htmlentities($comment['firstname'] . ' ' . $comment['lastname']); ?>:</strong> <?php echo $commenttext; ?> <small>(<?php echo relative_time($comment['posted']); ?>)</small><br><a href="<?php echo $comment['url']; ?>">Read annotation</a> | <a href="<?php echo $USERURL->generate(); ?>" title="See more information about this user">All by this user</a> </li>
40
+        ?><a name="c<?php echo $count; ?>"></a><strong><?php echo _htmlentities($comment['firstname'].' '.$comment['lastname']); ?>:</strong> <?php echo $commenttext; ?> <small>(<?php echo relative_time($comment['posted']); ?>)</small><br><a href="<?php echo $comment['url']; ?>">Read annotation</a> | <a href="<?php echo $USERURL->generate(); ?>" title="See more information about this user">All by this user</a> </li>
41 41
 <?php
42 42
     }
43 43
     ?>
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
     if ($this_page == 'home') {
48 48
         $MOREURL = new URL('comments_recent');
49 49
         ?>
50
-                        <p><a href="<?php echo $MOREURL->generate(); ?>#c<?php echo count($data['comments'])+1; ?>">See more annotations posted recently</a></p>
50
+                        <p><a href="<?php echo $MOREURL->generate(); ?>#c<?php echo count($data['comments']) + 1; ?>">See more annotations posted recently</a></p>
51 51
 <?php
52 52
     }
53 53
     if ($this_page != 'home') $PAGE->page_links($data);
Please login to merge, or discard this patch.
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -18,7 +18,9 @@  discard block
 block discarded – undo
18 18
     }
19 19
     $PAGE->block_start(array('id'=>'recentcomments', 'title'=>$title));
20 20
 
21
-    if ($this_page != 'home') $PAGE->page_links($data);
21
+    if ($this_page != 'home') {
22
+        $PAGE->page_links($data);
23
+    }
22 24
     $USERURL = new URL('userview');
23 25
     ?>
24 26
                         <ul>
@@ -50,7 +52,9 @@  discard block
 block discarded – undo
50 52
                         <p><a href="<?php echo $MOREURL->generate(); ?>#c<?php echo count($data['comments'])+1; ?>">See more annotations posted recently</a></p>
51 53
 <?php
52 54
     }
53
-    if ($this_page != 'home') $PAGE->page_links($data);
55
+    if ($this_page != 'home') {
56
+        $PAGE->page_links($data);
57
+    }
54 58
     $PAGE->block_end();
55 59
 }
56 60
 ?>
Please login to merge, or discard this patch.
www/includes/easyparliament/templates/html/people/index.php 1 patch
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -26,31 +26,31 @@  discard block
 block discarded – undo
26 26
                           Based on postcode <strong><?= $mp_data['postcode'] ?></strong>
27 27
                           <a href="<?= $mp_data['change_url'] ?>">(Change postcode)</a>
28 28
                       </p>
29
-                    <?php if ( isset( $mp_data ) && $type != 'mlas' ) { ?>
30
-                      <h3>Your <?= $mp_data['former'] ? $mp_data['former'] . ' ' : '' ?><?= $rep_name ?> is</h3>
29
+                    <?php if (isset($mp_data) && $type != 'mlas') { ?>
30
+                      <h3>Your <?= $mp_data['former'] ? $mp_data['former'].' ' : '' ?><?= $rep_name ?> is</h3>
31 31
                     </div>
32 32
                     <a href="<?= $mp_data['mp_url'] ?>" class="people-list__person">
33 33
                     <img class="people-list__person__image" src="<?= $mp_data['image'] ?>">
34 34
                         <h2 class="people-list__person__name"><?= $mp_data['name'] ?></h2>
35 35
                         <p class="people-list__person__memberships">
36 36
                         <span class="people-list__person__constituency"><?= $mp_data['constituency'] ?></span>
37
-                        <span class="people-list__person__party <?= strtolower( $mp_data['party'] ) ?>"><?= $mp_data['party'] ?></span>
37
+                        <span class="people-list__person__party <?= strtolower($mp_data['party']) ?>"><?= $mp_data['party'] ?></span>
38 38
                         </p>
39 39
                     </a>
40 40
                     <?php }
41
-                    if ( isset($reps) ) {
42
-                        if ( isset($mp_data) && $type != 'mlas' ) { ?>
41
+                    if (isset($reps)) {
42
+                        if (isset($mp_data) && $type != 'mlas') { ?>
43 43
                     <div class="people-list__your-mp__replist-header">
44 44
                         <?php } ?>
45 45
                       <h3>Your <?=$former ?> <?= $rep_plural == 'MSPs' ? 'regional ' : '' ?><?= $rep_plural ?> are</h3>
46 46
                     </div>
47
-                        <?php foreach ( $reps as $rep ) { ?>
47
+                        <?php foreach ($reps as $rep) { ?>
48 48
                     <a href="<?= $rep['mp_url'] ?>" class="people-list__person">
49 49
                     <img class="people-list__person__image" src="<?= $rep['image'] ?>">
50 50
                         <h2 class="people-list__person__name"><?= $rep['name'] ?></h2>
51 51
                         <p class="people-list__person__memberships">
52 52
                         <span class="people-list__person__constituency"><?= $rep['constituency'] ?></span>
53
-                        <span class="people-list__person__party <?= strtolower( $rep['party'] ) ?>"><?= $rep['party'] ?></span>
53
+                        <span class="people-list__person__party <?= strtolower($rep['party']) ?>"><?= $rep['party'] ?></span>
54 54
                         </p>
55 55
                     </a>
56 56
                         <?php } ?>
@@ -65,9 +65,9 @@  discard block
 block discarded – undo
65 65
             <div class="search-page__section search-page__section--search">
66 66
                 <div class="search-page__section__primary">
67 67
                     <p class="search-page-main-inputs">
68
-                    <?php if ( $type == 'peers' ) { ?>
68
+                    <?php if ($type == 'peers') { ?>
69 69
                         <label for="find-mp-by-name-or-postcode">Find <?= $rep_plural ?> by name:</label>
70
-                    <?php } elseif ( $type == 'mlas' || $type == 'msps' ) { ?>
70
+                    <?php } elseif ($type == 'mlas' || $type == 'msps') { ?>
71 71
                         <label for="find-mp-by-name-or-postcode">Find your <?= $rep_name ?> by postcode:</label>
72 72
                     <?php } else { ?>
73 73
                         <label for="find-mp-by-name-or-postcode">Find your <?= $rep_name ?> by name or postcode:</label>
@@ -108,12 +108,12 @@  discard block
 block discarded – undo
108 108
             <div class="search-page__section__primary">
109 109
             <h2>All <?= $rep_plural ?></h2>
110 110
 
111
-                <?php if ( $type != 'peers' ) { ?>
111
+                <?php if ($type != 'peers') { ?>
112 112
                 <ul class="search-result-display-options">
113
-                    <?php if ( $order == 'given_name' ) { ?>
113
+                    <?php if ($order == 'given_name') { ?>
114 114
                     <li><strong>Sorted by</strong> First name</li>
115 115
                     <li>Sort by <a href="<?= $urls['by_last'] ?>">Last name</a> / <a href="<?= $urls['by_party'] ?>">Party</a></li>
116
-                    <?php } else if ( $order == 'party' ) { ?>
116
+                    <?php } else if ($order == 'party') { ?>
117 117
                     <li><strong>Sorted by</strong> Party</li>
118 118
                     <li>Sort by <a href="<?= $urls['by_first'] ?>">First name</a> / <a href="<?= $urls['by_last'] ?>">Last name</a></li>
119 119
                     <?php } else { ?>
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
                 </ul>
124 124
                 <?php } else { ?>
125 125
                 <ul class="search-result-display-options">
126
-                    <?php if ( $order == 'party' ) { ?>
126
+                    <?php if ($order == 'party') { ?>
127 127
                     <li><strong>Sorted by</strong> Party</li>
128 128
                     <li>Sort by <a href="<?= $urls['by_name'] ?>">Name</a></li>
129 129
                     <?php } else { ?>
@@ -173,10 +173,10 @@  discard block
 block discarded – undo
173 173
                     }
174 174
                 }
175 175
                 $initial_link = '';
176
-                foreach ( $data as $person ) {
176
+                foreach ($data as $person) {
177 177
                     if ($order != 'party') {
178
-                        $initial = substr( strtoupper($person[$a_to_z_key]), 0, 1);
179
-                        if ( $initial != $current_initial ) {
178
+                        $initial = substr(strtoupper($person[$a_to_z_key]), 0, 1);
179
+                        if ($initial != $current_initial) {
180 180
                             $current_initial = $initial;
181 181
                             $initial_link = "name=\"$initial\" ";
182 182
                         } else {
@@ -188,7 +188,7 @@  discard block
 block discarded – undo
188 188
                 <img class="people-list__person__image" src="<?= $person['image'] ?>">
189 189
                         <h2 class="people-list__person__name"><?= ucfirst($person['name']) ?></h2>
190 190
                         <p class="people-list__person__memberships">
191
-                        <?php if ( $person['constituency'] ) { ?>
191
+                        <?php if ($person['constituency']) { ?>
192 192
                         <span class="people-list__person__constituency"><?= $person['constituency'] ?></span>
193 193
                         <?php } ?>
194 194
                         <span class="people-list__person__party <?= strtolower($person['party']) ?>"><?= $person['party'] ?></span>
@@ -206,7 +206,7 @@  discard block
 block discarded – undo
206 206
                 <a href="<?= $urls['by_csv'] ?>">Download this list as a CSV</a>
207 207
                     suitable for Excel
208 208
                 </p>
209
-                <?php if ( $type == 'mps' ) { ?>
209
+                <?php if ($type == 'mps') { ?>
210 210
                 <form method="get" action="<?= $urls['plain'] ?>" class="sidebar-item-with-icon sidebar-item-with-icon--date">
211 211
                     <p>
212 212
                         Or view a past list
@@ -250,7 +250,7 @@  discard block
 block discarded – undo
250 250
                   })
251 251
                 });
252 252
                 </script>
253
-                <?php } else if ( $type == 'msps' ) { ?>
253
+                <?php } else if ($type == 'msps') { ?>
254 254
                     <p class="past-list-dates" id="past-list-dates">
255 255
                         <a href="<?= $urls['plain'] ?>?date=2011-05-05">MSPs at 2011 election</a>
256 256
                         <a href="<?= $urls['plain'] ?>?date=2007-05-03">MSPs at 2007 election</a>
@@ -264,7 +264,7 @@  discard block
 block discarded – undo
264 264
                     </p>
265 265
                 <?php } ?>
266 266
 
267
-                <?php include( dirname(__FILE__) . '/../sidebar/looking_for.php' ) ?>
267
+                <?php include(dirname(__FILE__).'/../sidebar/looking_for.php') ?>
268 268
             </div>
269 269
         </div>
270 270
 
Please login to merge, or discard this patch.
www/includes/easyparliament/templates/html/index.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
             <div class="panel panel--flushtop clearfix">
46 46
                 <div class="row nested-row">
47 47
                     <div class="homepage-in-the-news homepage-content-section">
48
-                        <?php if ( count($featured) > 0 ) {
48
+                        <?php if (count($featured) > 0) {
49 49
                             include 'homepage/featured.php';
50 50
                         } else { ?>
51 51
                             No debates found.
@@ -100,14 +100,14 @@  discard block
 block discarded – undo
100 100
                     <div class="homepage-recently homepage-content-section">
101 101
                         <h2>Recently in Parliament</h2>
102 102
                         <ul class="recently__list"><?php
103
-                            foreach ( $debates['recent'] as $recent ) {
103
+                            foreach ($debates['recent'] as $recent) {
104 104
                                 include 'homepage/recent-debates.php';
105 105
                             }
106 106
                         ?></ul>
107 107
                     </div>
108 108
                     <div class="homepage-upcoming homepage-content-section">
109 109
                         <h2>Upcoming</h2>
110
-                        <?php if ( count($calendar) ) { ?>
110
+                        <?php if (count($calendar)) { ?>
111 111
                         <div class="upcoming__controls">
112 112
                             <!--
113 113
                                 These controls should make the upcoming section slide to the next day.
@@ -126,25 +126,25 @@  discard block
 block discarded – undo
126 126
                             </div>
127 127
                         </div>
128 128
                         <?php $first = true; $count = 0;
129
-                            foreach ( $calendar as $date => $places ) {
129
+                            foreach ($calendar as $date => $places) {
130 130
                                 $count++; ?>
131 131
                                 <div class="cal-wrapper <?= $first ? 'visible' : 'hidden' ?>" id="day-<?= $count ?>" data-count="<?= $count ?>" data-date="<?= format_date($date, SHORTDATEFORMAT); ?>">
132 132
                                 <?php foreach ($places as $place => $events) { ?>
133 133
                                     <?php $first = false; ?>
134 134
                                     <h3><?= $place ?></h3>
135 135
                                     <ul class="upcoming__list">
136
-                                        <?php for ( $i = 0; $i < 3; $i++ ) {
137
-                                            if ( isset( $events[$i] ) ) { ?>
136
+                                        <?php for ($i = 0; $i < 3; $i++) {
137
+                                            if (isset($events[$i])) { ?>
138 138
                                         <li>
139 139
                                             <h4 class="upcoming__title"><a href="<?= $events[$i]['link_external'] ?>"><?= $events[$i]['title'] ?></a></h4>
140 140
                                             <p class="meta"><?php
141 141
                                                 $meta_items = array();
142 142
                                                 $meta_items[] = $events[$i]['debate_type'];
143
-                                                if( isset($events[$i]['time_start']) && $events[$i]['time_start'] != '00:00:00' ){
143
+                                                if (isset($events[$i]['time_start']) && $events[$i]['time_start'] != '00:00:00') {
144 144
                                                     $times = format_time($events[$i]['time_start'], 'g:i a');
145 145
 
146
-                                                    if( isset($events[$i]['time_end']) && $events[$i]['time_end'] != '00:00:00' ){
147
-                                                        $times = $times . ' - ' . format_time($events[$i]['time_end'], 'g:i a');
146
+                                                    if (isset($events[$i]['time_end']) && $events[$i]['time_end'] != '00:00:00') {
147
+                                                        $times = $times.' - '.format_time($events[$i]['time_end'], 'g:i a');
148 148
                                                     }
149 149
                                                     $meta_items[] = $times;
150 150
                                                 }
@@ -155,7 +155,7 @@  discard block
 block discarded – undo
155 155
                                         <?php } ?>
156 156
                                         <?php } ?>
157 157
                                     </ul>
158
-                                    <?php if ( count($events) - 3 > 0 ) { ?>
158
+                                    <?php if (count($events) - 3 > 0) { ?>
159 159
                                     <a href="/calendar/?d=<?= format_date($date, 'Y-m-d') ?>" class="upcoming__more">And <?= count($events) - 3 ?> more</a><!-- (just links to relevant upcoming page) -->
160 160
                                     <?php } ?>
161 161
                             <?php } ?>
@@ -163,7 +163,7 @@  discard block
 block discarded – undo
163 163
                         <?php } ?>
164 164
                         <?php } else {
165 165
                             list($recess, $from, $to) = recess_prettify(date('j'), date('n'), date('Y'), 1);
166
-                            if ( $recess ) { ?>
166
+                            if ($recess) { ?>
167 167
                                 <p>
168 168
                                 Parliament is on holiday until <?= format_date($to, LONGERDATEFORMAT) ?>.
169 169
                                 Follow us on <a href="https://twitter.com/theyworkforyou">Twitter</a> and you'll
Please login to merge, or discard this patch.