Passed
Push — 2.x ( 327f41...fd069b )
by Terry
02:13
created
templates/panel/action_log_last_month.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -60,9 +60,12 @@
 block discarded – undo
60 60
                 </div>
61 61
             </div>
62 62
         </div>
63
-    <?php else : ?>
63
+    <?php else {
64
+    : ?>
64 65
         <div class="alert alert-danger">
65
-            <?php _e('panel', 'log_msg_no_logger', 'Sorry, you have to implement ActionLogger to use this function.'); ?>
66
+            <?php _e('panel', 'log_msg_no_logger', 'Sorry, you have to implement ActionLogger to use this function.');
67
+}
68
+?>
66 69
             
67 70
         </div>
68 71
     <?php endif; ?>
Please login to merge, or discard this patch.
templates/panel/exclusion.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -62,7 +62,8 @@  discard block
 block discarded – undo
62 62
             </tbdoy>
63 63
         </table>
64 64
     </div>
65
-    <?php else: ?>
65
+    <?php else {
66
+    : ?>
66 67
     <div id="so-table-loading" class="so-datatables">
67 68
         <div class="lds-css ng-scope">
68 69
             <div class="lds-ripple">
@@ -71,7 +72,9 @@  discard block
 block discarded – undo
71 72
             </div>
72 73
         </div>
73 74
     </div>
74
-    <?php endif; ?>
75
+    <?php endif;
76
+}
77
+?>
75 78
     <div id="so-table-container" class="so-datatables" style="display: none;">
76 79
         <table id="so-datalog" class="cell-border compact stripe responsive" cellspacing="0" width="100%">
77 80
             <thead>
Please login to merge, or discard this patch.
templates/panel/action_log_this_month.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -60,9 +60,12 @@
 block discarded – undo
60 60
                 </div>
61 61
             </div>
62 62
         </div>
63
-    <?php else : ?>
63
+    <?php else {
64
+    : ?>
64 65
         <div class="alert alert-danger">
65
-            <?php _e('panel', 'log_msg_no_logger', 'Sorry, you have to implement ActionLogger to use this function.'); ?>
66
+            <?php _e('panel', 'log_msg_no_logger', 'Sorry, you have to implement ActionLogger to use this function.');
67
+}
68
+?>
66 69
             
67 70
         </div>
68 71
     <?php endif; ?>
Please login to merge, or discard this patch.
templates/panel/action_log_today.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -60,9 +60,12 @@
 block discarded – undo
60 60
                 </div>
61 61
             </div>
62 62
         </div>
63
-    <?php else : ?>
63
+    <?php else {
64
+    : ?>
64 65
         <div class="alert alert-danger">
65
-            <?php _e('panel', 'log_msg_no_logger', 'Sorry, you have to implement ActionLogger to use this function.'); ?>
66
+            <?php _e('panel', 'log_msg_no_logger', 'Sorry, you have to implement ActionLogger to use this function.');
67
+}
68
+?>
66 69
             
67 70
         </div>
68 71
     <?php endif; ?>
Please login to merge, or discard this patch.
templates/panel/action_log_yesterday.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -60,9 +60,12 @@
 block discarded – undo
60 60
                 </div>
61 61
             </div>
62 62
         </div>
63
-    <?php else : ?>
63
+    <?php else {
64
+    : ?>
64 65
         <div class="alert alert-danger">
65
-            <?php _e('panel', 'log_msg_no_logger', 'Sorry, you have to implement ActionLogger to use this function.'); ?>
66
+            <?php _e('panel', 'log_msg_no_logger', 'Sorry, you have to implement ActionLogger to use this function.');
67
+}
68
+?>
66 69
             
67 70
         </div>
68 71
     <?php endif; ?>
Please login to merge, or discard this patch.
templates/panel/overview.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -203,7 +203,7 @@  discard block
 block discarded – undo
203 203
                 <div class="filter-status">
204 204
                     <div class="heading"><?php _e('panel', 'overview_label_action_logger', 'Action Logger'); ?></div>
205 205
                     <div class="nums">
206
-                        <?php echo $data['action_logger']  ? '<i class="far fa-play-circle"></i>' : '<i class="far fa-stop-circle"></i>'; ?>
206
+                        <?php echo $data['action_logger'] ? '<i class="far fa-play-circle"></i>' : '<i class="far fa-stop-circle"></i>'; ?>
207 207
                     </div>
208 208
                     <div class="note"><?php _e('panel', 'overview_note_action_logger', 'Record every visitor’s behavior.'); ?></div>
209 209
                 </div>
@@ -222,7 +222,7 @@  discard block
 block discarded – undo
222 222
                 <div class="filter-status">
223 223
                     <div class="heading"><?php _e('panel', 'overview_label_recaptcha', 'reCAPTCHA'); ?></div>
224 224
                     <div class="nums">
225
-                        <?php echo $captcha['recaptcha']  ? '<i class="far fa-play-circle"></i>' : '<i class="far fa-stop-circle"></i>'; ?>
225
+                        <?php echo $captcha['recaptcha'] ? '<i class="far fa-play-circle"></i>' : '<i class="far fa-stop-circle"></i>'; ?>
226 226
                     </div>
227 227
                     <div class="note"><?php _e('panel', 'overview_note_recaptcha', 'Provided by Google.'); ?></div>
228 228
                 </div>
@@ -231,7 +231,7 @@  discard block
 block discarded – undo
231 231
                 <div class="filter-status">
232 232
                     <div class="heading"><?php _e('panel', 'overview_label_image_captcha', 'Image Captcha'); ?></div>
233 233
                     <div class="nums">
234
-                        <?php echo $captcha['imagecaptcha']  ? '<i class="far fa-play-circle"></i>' : '<i class="far fa-stop-circle"></i>'; ?>
234
+                        <?php echo $captcha['imagecaptcha'] ? '<i class="far fa-play-circle"></i>' : '<i class="far fa-stop-circle"></i>'; ?>
235 235
                     </div>
236 236
                     <div class="note"><?php _e('panel', 'overview_note_image_captcha', 'A simple text-in-image Captcha.'); ?></div>
237 237
                 </div>
@@ -251,7 +251,7 @@  discard block
 block discarded – undo
251 251
                 <div class="filter-status">
252 252
                     <div class="heading"><?php _e('panel', 'overview_label_' . $k, ''); ?></div>
253 253
                     <div class="nums">
254
-                        <?php echo $messengers[$k]  ? '<i class="far fa-play-circle"></i>' : '<i class="far fa-stop-circle"></i>'; ?>
254
+                        <?php echo $messengers[$k] ? '<i class="far fa-play-circle"></i>' : '<i class="far fa-stop-circle"></i>'; ?>
255 255
                     </div>
256 256
                     <div class="note"><?php _e('panel', 'overview_note_' . $k, ''); ?></div>
257 257
                 </div>
Please login to merge, or discard this patch.
templates/panel/xss_protection.php 2 patches
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -62,7 +62,8 @@  discard block
 block discarded – undo
62 62
             </tbdoy>
63 63
         </table>
64 64
     </div>
65
-    <?php else: ?>
65
+    <?php else {
66
+    : ?>
66 67
     <div id="so-table-loading" class="so-datatables">
67 68
         <div class="lds-css ng-scope">
68 69
             <div class="lds-ripple">
@@ -71,7 +72,9 @@  discard block
 block discarded – undo
71 72
             </div>
72 73
         </div>
73 74
     </div>
74
-    <?php endif; ?>
75
+    <?php endif;
76
+}
77
+?>
75 78
     <div id="so-table-container" class="so-datatables" style="display: none;">
76 79
         <table id="so-datalog" class="cell-border compact stripe responsive" cellspacing="0" width="100%">
77 80
             <thead>
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -128,7 +128,7 @@
 block discarded – undo
128 128
         </div>
129 129
     </div>
130 130
     <br />
131
-    <?php if ( empty($xss_protected_list)) : ?>
131
+    <?php if (empty($xss_protected_list)) : ?>
132 132
     <div id="so-table-container" class="so-datatables">
133 133
         <table id="so-datalog" class="cell-border compact stripe responsive" cellspacing="0" width="100%">
134 134
             <tbody>
Please login to merge, or discard this patch.
src/Firewall/Panel/Home.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -236,11 +236,11 @@
 block discarded – undo
236 236
     private function overviewTemplateVarsOfComponents(array $data = []): array
237 237
     {
238 238
         $data['components'] = [
239
-            'Ip'         => (!empty($this->kernel->component['Ip']))         ? true : false,
239
+            'Ip'         => (!empty($this->kernel->component['Ip'])) ? true : false,
240 240
             'TrustedBot' => (!empty($this->kernel->component['TrustedBot'])) ? true : false,
241
-            'Header'     => (!empty($this->kernel->component['Header']))     ? true : false,
242
-            'Rdns'       => (!empty($this->kernel->component['Rdns']))       ? true : false,
243
-            'UserAgent'  => (!empty($this->kernel->component['UserAgent']))  ? true : false,
241
+            'Header'     => (!empty($this->kernel->component['Header'])) ? true : false,
242
+            'Rdns'       => (!empty($this->kernel->component['Rdns'])) ? true : false,
243
+            'UserAgent'  => (!empty($this->kernel->component['UserAgent'])) ? true : false,
244 244
         ];
245 245
 
246 246
         return $data;
Please login to merge, or discard this patch.
src/Firewall/Panel/Report.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -127,7 +127,7 @@  discard block
 block discarded – undo
127 127
                 $data['period_data'] = $ipDetailsCachedData['period_data'];
128 128
                 $lastCachedTime = date('Y-m-d H:i:s', $ipDetailsCachedData['time']);
129 129
     
130
-                if ('today' === $type ) {
130
+                if ('today' === $type) {
131 131
                     $ipDetailsCachedData = $logCacheHandler->get('past_seven_hours');
132 132
                     $data['past_seven_hours'] = $ipDetailsCachedData['period_data'];
133 133
                 }
@@ -141,7 +141,7 @@  discard block
 block discarded – undo
141 141
 
142 142
                 $logCacheHandler->save($type, $data);
143 143
     
144
-                if ('today' === $type ) {
144
+                if ('today' === $type) {
145 145
                     $this->parser->prepare('past_seven_hours');
146 146
                     $data['past_seven_hours'] = $this->parser->getParsedPeriodData();
147 147
 
@@ -172,11 +172,11 @@  discard block
 block discarded – undo
172 172
     private function operationTemplateVarsOfComponents(array $data = []): array
173 173
     {
174 174
         $data['components'] = [
175
-            'Ip'         => (!empty($this->kernel->component['Ip']))         ? true : false,
175
+            'Ip'         => (!empty($this->kernel->component['Ip'])) ? true : false,
176 176
             'TrustedBot' => (!empty($this->kernel->component['TrustedBot'])) ? true : false,
177
-            'Header'     => (!empty($this->kernel->component['Header']))     ? true : false,
178
-            'Rdns'       => (!empty($this->kernel->component['Rdns']))       ? true : false,
179
-            'UserAgent'  => (!empty($this->kernel->component['UserAgent']))  ? true : false,
177
+            'Header'     => (!empty($this->kernel->component['Header'])) ? true : false,
178
+            'Rdns'       => (!empty($this->kernel->component['Rdns'])) ? true : false,
179
+            'UserAgent'  => (!empty($this->kernel->component['UserAgent'])) ? true : false,
180 180
         ];
181 181
 
182 182
         return $data;
Please login to merge, or discard this patch.