Code Duplication    Length = 6-8 lines in 3 locations

includes/auth/AuthManager.php 3 locations

@@ 609-614 (lines=6) @@
606
					case AuthenticationResponse::ABSTAIN;
607
						$state['secondary'][$id] = true;
608
						break;
609
					case AuthenticationResponse::FAIL;
610
						$this->logger->debug( "Login failed in secondary authentication by $id" );
611
						$this->callMethodOnProviders( 7, 'postAuthentication', [ $user, $res ] );
612
						$session->remove( 'AuthManager::authnState' );
613
						\Hooks::run( 'AuthManagerLoginAuthenticateAudit', [ $res, $user, $user->getName() ] );
614
						return $res;
615
					case AuthenticationResponse::REDIRECT;
616
					case AuthenticationResponse::UI;
617
						$this->logger->debug( "Secondary login with $id returned " . $res->status );
@@ 1267-1274 (lines=8) @@
1264
							$state['primary'] = $id;
1265
							$state['primaryResponse'] = $res;
1266
							break 2;
1267
						case AuthenticationResponse::FAIL;
1268
							$this->logger->debug( __METHOD__ . ": Primary creation failed by $id", [
1269
								'user' => $user->getName(),
1270
								'creator' => $creator->getName(),
1271
							] );
1272
							$this->callMethodOnProviders( 7, 'postAccountCreation', [ $user, $creator, $res ] );
1273
							$session->remove( 'AuthManager::accountCreationState' );
1274
							return $res;
1275
						case AuthenticationResponse::ABSTAIN;
1276
							// Continue loop
1277
							break;
@@ 1332-1339 (lines=8) @@
1329
						] );
1330
						$state['primaryResponse'] = $res;
1331
						break;
1332
					case AuthenticationResponse::FAIL;
1333
						$this->logger->debug( __METHOD__ . ": Primary creation failed by $id", [
1334
							'user' => $user->getName(),
1335
							'creator' => $creator->getName(),
1336
						] );
1337
						$this->callMethodOnProviders( 7, 'postAccountCreation', [ $user, $creator, $res ] );
1338
						$session->remove( 'AuthManager::accountCreationState' );
1339
						return $res;
1340
					case AuthenticationResponse::REDIRECT;
1341
					case AuthenticationResponse::UI;
1342
						$this->logger->debug( __METHOD__ . ": Primary creation $res->status by $id", [