Code Duplication    Length = 13-13 lines in 2 locations

includes/auth/AuthManager.php 2 locations

@@ 416-428 (lines=13) @@
413
							$state['primaryResponse'] = $res;
414
							$this->logger->debug( "Primary login with $id succeeded" );
415
							break 2;
416
						case AuthenticationResponse::FAIL;
417
							$this->logger->debug( "Login failed in primary authentication by $id" );
418
							if ( $res->createRequest || $state['maybeLink'] ) {
419
								$res->createRequest = new CreateFromLoginAuthenticationRequest(
420
									$res->createRequest, $state['maybeLink']
421
								);
422
							}
423
							$this->callMethodOnProviders( 7, 'postAuthentication',
424
								[ User::newFromName( $guessUserName ) ?: null, $res ]
425
							);
426
							$session->remove( 'AuthManager::authnState' );
427
							\Hooks::run( 'AuthManagerLoginAuthenticateAudit', [ $res, null, $guessUserName ] );
428
							return $res;
429
						case AuthenticationResponse::ABSTAIN;
430
							// Continue loop
431
							break;
@@ 481-493 (lines=13) @@
478
						$state['primaryResponse'] = $res;
479
						$this->logger->debug( "Primary login with $id succeeded" );
480
						break;
481
					case AuthenticationResponse::FAIL;
482
						$this->logger->debug( "Login failed in primary authentication by $id" );
483
						if ( $res->createRequest || $state['maybeLink'] ) {
484
							$res->createRequest = new CreateFromLoginAuthenticationRequest(
485
								$res->createRequest, $state['maybeLink']
486
							);
487
						}
488
						$this->callMethodOnProviders( 7, 'postAuthentication',
489
							[ User::newFromName( $guessUserName ) ?: null, $res ]
490
						);
491
						$session->remove( 'AuthManager::authnState' );
492
						\Hooks::run( 'AuthManagerLoginAuthenticateAudit', [ $res, null, $guessUserName ] );
493
						return $res;
494
					case AuthenticationResponse::REDIRECT;
495
					case AuthenticationResponse::UI;
496
						$this->logger->debug( "Primary login with $id returned $res->status" );