Passed
Push — master ( de1c6e...8badc5 )
by Stanislav
14:22 queued 11:27
created
core/notification.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -244,8 +244,7 @@
 block discarded – undo
244 244
 		if (is_array($ids))
245 245
 		{
246 246
 			return array_map('intval', $ids);
247
-		}
248
-		else
247
+		} else
249 248
 		{
250 249
 			return array((int) $ids);
251 250
 		}
Please login to merge, or discard this patch.
core/notification/helper.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -244,8 +244,7 @@
 block discarded – undo
244 244
 		if (is_array($ids))
245 245
 		{
246 246
 			return array_map('intval', $ids);
247
-		}
248
-		else
247
+		} else
249 248
 		{
250 249
 			return array((int) $ids);
251 250
 		}
Please login to merge, or discard this patch.
core/moderate.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -85,8 +85,7 @@  discard block
 block discarded – undo
85 85
 			{
86 86
 				$mod_array[] = 0;
87 87
 			}
88
-		}
89
-		else
88
+		} else
90 89
 		{
91 90
 			$mod_array = array($album);
92 91
 		}
@@ -162,8 +161,7 @@  discard block
 block discarded – undo
162 161
 			$this->template->assign_vars(array(
163 162
 				'TOTAL_PAGES' => $this->lang->lang('PAGE_TITLE_NUMBER', $page + 1),
164 163
 			));
165
-		}
166
-		else
164
+		} else
167 165
 		{
168 166
 			$this->pagination->generate_template_pagination(array(
169 167
 				'routes' => array(
Please login to merge, or discard this patch.
core/user.php 1 patch
Braces   +7 added lines, -14 removed lines patch added patch discarded remove patch
@@ -160,8 +160,7 @@  discard block
 block discarded – undo
160 160
 		if (isset($this->data[$key]))
161 161
 		{
162 162
 			return $this->data[$key];
163
-		}
164
-		else if ($default && $this->get_default_value($key) !== null)
163
+		} else if ($default && $this->get_default_value($key) !== null)
165 164
 		{
166 165
 			return $this->get_default_value($key);
167 166
 		}
@@ -359,12 +358,10 @@  discard block
 block discarded – undo
359 358
 		if (is_array($user_ids) && !empty($user_ids))
360 359
 		{
361 360
 			$sql_where = 'WHERE ' . $this->db->sql_in_set('user_id', array_map('intval', $user_ids));
362
-		}
363
-		else if ($user_ids == 'all')
361
+		} else if ($user_ids == 'all')
364 362
 		{
365 363
 			$sql_where = '';
366
-		}
367
-		else
364
+		} else
368 365
 		{
369 366
 			$sql_where = 'WHERE user_id = ' . (int) $user_ids;
370 367
 		}
@@ -395,8 +392,7 @@  discard block
 block discarded – undo
395 392
 					{
396 393
 						// While incrementing, the iamges might be lower than 0.
397 394
 						$validated_data[$name] = (int) $value;
398
-					}
399
-					else
395
+					} else
400 396
 					{
401 397
 						$validated_data[$name] = max(0, (int) $value);
402 398
 					}
@@ -542,8 +538,7 @@  discard block
 block discarded – undo
542 538
 					'warnings'            => 0,
543 539
 					'allow_pm'            => 0,
544 540
 				);
545
-			}
546
-			else
541
+			} else
547 542
 			{
548 543
 				$user_sig = '';
549 544
 				// We add the signature to every posters entry because enable_sig is post dependent
@@ -589,8 +584,7 @@  discard block
 block discarded – undo
589 584
 				if ((!empty($row['user_allow_viewemail']) && $this->auth->acl_get('u_sendemail')) || $this->auth->acl_get('a_email'))
590 585
 				{
591 586
 					$user_cache[$user_id]['email'] = ($this->config['board_email_form'] && $this->config['email_enable']) ? append_sid("{$this->root_path}memberlist.$this->php_ext", "mode=email&u=$user_id") : (($this->config['board_hide_emails'] && !$this->auth->acl_get('a_email')) ? '' : 'mailto:' . $row['user_email']);
592
-				}
593
-				else
587
+				} else
594 588
 				{
595 589
 					$user_cache[$user_id]['email'] = '';
596 590
 				}
@@ -603,8 +597,7 @@  discard block
 block discarded – undo
603 597
 						if ($diff == 0)
604 598
 						{
605 599
 							$diff = ($now['mday'] - $bday_day < 0) ? 1 : 0;
606
-						}
607
-						else
600
+						} else
608 601
 						{
609 602
 							$diff = ($diff < 0) ? 1 : 0;
610 603
 						}
Please login to merge, or discard this patch.
core/album/album.php 1 patch
Braces   +9 added lines, -18 removed lines patch added patch discarded remove patch
@@ -222,8 +222,7 @@  discard block
 block discarded – undo
222 222
 			{
223 223
 				$padding .= '&nbsp; &nbsp;';
224 224
 				$padding_store[$row['parent_id']] = $padding;
225
-			}
226
-			else if ($row['left_id'] > $right + 1)
225
+			} else if ($row['left_id'] > $right + 1)
227 226
 			{
228 227
 				$padding = (isset($padding_store[$row['parent_id']])) ? $padding_store[$row['parent_id']] : '';
229 228
 			}
@@ -249,15 +248,13 @@  discard block
 block discarded – undo
249 248
 			if (($select_id == $this->gallery_auth->get_setting_permissions()) && !$row['album_user_id'])
250 249
 			{
251 250
 				$list = true;
252
-			}
253
-			else if (!$row['album_user_id'])
251
+			} else if (!$row['album_user_id'])
254 252
 			{
255 253
 				if ($this->gallery_auth->acl_check('a_list', $row['album_id'], $row['album_user_id']) || defined('IN_ADMIN'))
256 254
 				{
257 255
 					$list = true;
258 256
 				}
259
-			}
260
-			else if (!$ignore_personals)
257
+			} else if (!$ignore_personals)
261 258
 			{
262 259
 				if ($row['album_user_id'] == $this->user->data['user_id'])
263 260
 				{
@@ -268,16 +265,14 @@  discard block
 block discarded – undo
268 265
 						if ($requested_permission)
269 266
 						{
270 267
 							$requested_own = !$this->gallery_auth->acl_check($requested_permission, $this->gallery_auth->get_own_album());
271
-						}
272
-						else
268
+						} else
273 269
 						{
274 270
 							$requested_own = false; // We need the negated version of true here
275 271
 						}
276 272
 					}
277 273
 					$list = (!$list) ? $access_own : $list;
278 274
 					$disabled = (!$disabled) ? $requested_own : $disabled;
279
-				}
280
-				else if ($row['album_user_id'])
275
+				} else if ($row['album_user_id'])
281 276
 				{
282 277
 					if (!$c_access_personal)
283 278
 					{
@@ -286,8 +281,7 @@  discard block
 block discarded – undo
286 281
 						if ($requested_permission)
287 282
 						{
288 283
 							$requested_personal = !$this->gallery_auth->acl_check($requested_permission, $this->gallery_auth->get_personal_album());
289
-						}
290
-						else
284
+						} else
291 285
 						{
292 286
 							$requested_personal = false; // We need the negated version of true here
293 287
 						}
@@ -299,8 +293,7 @@  discard block
 block discarded – undo
299 293
 			if (($album_user_id != \phpbbgallery\core\block::PUBLIC_ALBUM) && ($album_user_id != $row['album_user_id']))
300 294
 			{
301 295
 				$list = false;
302
-			}
303
-			else if (($album_user_id != \phpbbgallery\core\block::PUBLIC_ALBUM) && ($row['parent_id'] == 0))
296
+			} else if (($album_user_id != \phpbbgallery\core\block::PUBLIC_ALBUM) && ($row['parent_id'] == 0))
304 297
 			{
305 298
 				$disabled = true;
306 299
 			}
@@ -318,8 +311,7 @@  discard block
 block discarded – undo
318 311
 			$gallery_albumbox = "<select name='$select_name' id='$select_name'>";
319 312
 			$gallery_albumbox .= $album_list;
320 313
 			$gallery_albumbox .= '</select>';
321
-		}
322
-		else
314
+		} else
323 315
 		{
324 316
 			$gallery_albumbox = $album_list;
325 317
 		}
@@ -388,8 +380,7 @@  discard block
 block discarded – undo
388 380
 				'album_last_user_colour' => $row['image_user_colour'],
389 381
 				'album_last_user_id'     => $row['image_user_id'],
390 382
 			);
391
-		}
392
-		else
383
+		} else
393 384
 		{
394 385
 			// No approved image, so we clear the columns
395 386
 			$sql_ary = array(
Please login to merge, or discard this patch.
core/log.php 1 patch
Braces   +4 added lines, -8 removed lines patch added patch discarded remove patch
@@ -204,8 +204,7 @@  discard block
 block discarded – undo
204 204
 					$sql_array['GROUP_BY'] = 'l.description, l.log_id, i.image_id';
205 205
 				break;
206 206
 			}
207
-		}
208
-		else
207
+		} else
209 208
 		{
210 209
 			$sql_array['ORDER_BY'] = 'l.log_time ' . (isset($additional['sort_dir']) ? 'ASC' : 'DESC');
211 210
 			$sql_array['GROUP_BY'] = 'l.log_time, l.log_id, i.image_id';
@@ -219,8 +218,7 @@  discard block
 block discarded – undo
219 218
 		if ($row)
220 219
 		{
221 220
 			$count = $row['count'];
222
-		}
223
-		else
221
+		} else
224 222
 		{
225 223
 			$count = 0;
226 224
 		}
@@ -281,8 +279,7 @@  discard block
 block discarded – undo
281 279
 				'params' => array(
282 280
 				),
283 281
 			), 'pagination', 'page', $count, $limit, ($page-1) * $limit);
284
-		}
285
-		else if ($album == -1)
282
+		} else if ($album == -1)
286 283
 		{
287 284
 			$url_array = array(
288 285
 				'i' => '-phpbbgallery-core-acp-gallery_logs_module',
@@ -303,8 +300,7 @@  discard block
 block discarded – undo
303 300
 			$url = http_build_query($url_array,'','&');
304 301
 
305 302
 			$this->pagination->generate_template_pagination(append_sid('index.php?' . $url), 'pagination', 'page', $count, $limit, ($page-1) * $limit);
306
-		}
307
-		else
303
+		} else
308 304
 		{
309 305
 			$this->pagination->generate_template_pagination(array(
310 306
 				'routes' => array(
Please login to merge, or discard this patch.
core/image/image.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -363,8 +363,7 @@  discard block
 block discarded – undo
363 363
 				{
364 364
 					$url = $this->url->append_sid('image_page', "album_id=$album_id&amp;image_id=$next_image{$additional_parameters}");
365 365
 					$tpl = '<a href="{IMAGE_URL}" title="{IMAGE_NAME}">{CONTENT}</a>';
366
-				}
367
-				else
366
+				} else
368 367
 				{
369 368
 					$tpl = '{CONTENT}';
370 369
 				}
@@ -440,8 +439,7 @@  discard block
 block discarded – undo
440 439
 		{
441 440
 			$this->gallery_config->inc('num_images', (int) $num_images);
442 441
 			$this->gallery_config->inc('num_comments', (int) $num_comments);
443
-		}
444
-		else
442
+		} else
445 443
 		{
446 444
 			$this->gallery_config->dec('num_images', (int) $num_images);
447 445
 			$this->gallery_config->dec('num_comments', (int) $num_comments);
Please login to merge, or discard this patch.
acpcleanup/acp/main_module.php 1 patch
Braces   +4 added lines, -8 removed lines patch added patch discarded remove patch
@@ -223,14 +223,12 @@  discard block
 block discarded – undo
223 223
 			}
224 224
 
225 225
 			trigger_error($message_string . adm_back_link($this->u_action));
226
-		}
227
-		else if ($delete || $prune || (isset($_POST['cancel'])))
226
+		} else if ($delete || $prune || (isset($_POST['cancel'])))
228 227
 		{
229 228
 			if (isset($_POST['cancel']))
230 229
 			{
231 230
 				trigger_error($user->lang['CLEAN_GALLERY_ABORT'] . adm_back_link($this->u_action), E_USER_WARNING);
232
-			}
233
-			else
231
+			} else
234 232
 			{
235 233
 				$clean_gallery_confirm = $user->lang['CONFIRM_CLEAN'];
236 234
 				if ($missing_sources)
@@ -261,8 +259,7 @@  discard block
 block discarded – undo
261 259
 						if (in_array($row['album_user_id'], $personals_bad))
262 260
 						{
263 261
 							$personals_bad_names[] = $row['album_name'];
264
-						}
265
-						else
262
+						} else
266 263
 						{
267 264
 							$missing_personals_names[] = $row['album_name'];
268 265
 						}
@@ -280,8 +277,7 @@  discard block
 block discarded – undo
280 277
 				if ($prune && empty($prune_pattern))
281 278
 				{
282 279
 					trigger_error($user->lang['CLEAN_PRUNE_NO_PATTERN'] . adm_back_link($this->u_action), E_USER_WARNING);
283
-				}
284
-				else if ($prune && $prune_pattern)
280
+				} else if ($prune && $prune_pattern)
285 281
 				{
286 282
 					$clean_gallery_confirm = $user->lang('CONFIRM_PRUNE', $core_cleanup->lang_prune_pattern($prune_pattern)) . '<br />' . $clean_gallery_confirm;
287 283
 				}
Please login to merge, or discard this patch.
core/controller/file.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -238,8 +238,7 @@  discard block
 block discarded – undo
238 238
 			$this->data['album_user_id'] = 1;
239 239
 			$this->data['image_filemissing'] = 0;
240 240
 			$this->data['album_watermark'] = 0;
241
-		}
242
-		else
241
+		} else
243 242
 		{
244 243
 			$sql = 'SELECT *
245 244
 				FROM ' . $this->table_images . ' i
@@ -409,8 +408,7 @@  discard block
 block discarded – undo
409 408
 			{
410 409
 				$response->headers->set('expires', '-1');
411 410
 			}
412
-		}
413
-		else
411
+		} else
414 412
 		{
415 413
 			$response->headers->set('Content-Disposition', 'inline; ' . $this->tool->header_filename(htmlspecialchars_decode($this->tool->image_name) . '.' . $this->tool->image_type));
416 414
 			if ($this->tool->is_ie_greater7($this->user->browser))
Please login to merge, or discard this patch.