Code Duplication    Length = 17-17 lines in 2 locations

acc.php 2 locations

@@ 405-421 (lines=17) @@
402
    
403
	$suspendstatement = $database->prepare($sqlText);
404
    
405
	if ($user->isDeclined()) {
406
		$suspendAction = "Declined";
407
		$userid = $user->getId();
408
		$suspendstatement->bindValue(":action", $suspendAction);
409
		$suspendstatement->bindValue(":userid", $userid);
410
		$suspendstatement->execute();
411
        
412
		$suspendreason = $suspendstatement->fetchColumn();
413
        
414
		$suspendstatement->closeCursor();
415
        
416
		BootstrapSkin::displayInternalHeader();
417
		$smarty->assign("suspendreason", $suspendreason);
418
		$smarty->display("login/declined.tpl");
419
		BootstrapSkin::displayInternalFooter();
420
		die();
421
	}
422
    
423
	if ($user->isSuspended()) {
424
		$suspendAction = "Suspended";
@@ 423-439 (lines=17) @@
420
		die();
421
	}
422
    
423
	if ($user->isSuspended()) {
424
		$suspendAction = "Suspended";
425
		$userid = $user->getId();
426
		$suspendstatement->bindValue(":action", $suspendAction);
427
		$suspendstatement->bindValue(":userid", $userid);
428
		$suspendstatement->execute();
429
        
430
		$suspendreason = $suspendstatement->fetchColumn();
431
        
432
		$suspendstatement->closeCursor();
433
        
434
		BootstrapSkin::displayInternalHeader();
435
		$smarty->assign("suspendreason", $suspendreason);
436
		$smarty->display("login/suspended.tpl");
437
		BootstrapSkin::displayInternalFooter();
438
		die();
439
	}
440
    
441
	if (!$user->isIdentified() && $forceIdentification == 1) {
442
		header("Location: $baseurl/acc.php?error=noid");