Code Duplication    Length = 9-15 lines in 2 locations

core/Middleware/TwoFactorMiddleware.php 1 location

@@ 65-73 (lines=9) @@
62
	 * @param ISession $session
63
	 * @param IURLGenerator $urlGenerator
64
	 */
65
	public function __construct(Manager $twoFactorManager, Session $userSession, ISession $session,
66
		IURLGenerator $urlGenerator, IControllerMethodReflector $reflector, IRequest $request) {
67
		$this->twoFactorManager = $twoFactorManager;
68
		$this->userSession = $userSession;
69
		$this->session = $session;
70
		$this->urlGenerator = $urlGenerator;
71
		$this->reflector = $reflector;
72
		$this->request = $request;
73
	}
74
75
	/**
76
	 * @param Controller $controller

apps/dav/lib/Connector/Sabre/Auth.php 1 location

@@ 69-83 (lines=15) @@
66
	 * @param Manager $twoFactorManager
67
	 * @param string $principalPrefix
68
	 */
69
	public function __construct(ISession $session,
70
								Session $userSession,
71
								IRequest $request,
72
								Manager $twoFactorManager,
73
								$principalPrefix = 'principals/users/') {
74
		$this->session = $session;
75
		$this->userSession = $userSession;
76
		$this->twoFactorManager = $twoFactorManager;
77
		$this->request = $request;
78
		$this->principalPrefix = $principalPrefix;
79
80
		// setup realm
81
		$defaults = new \OC_Defaults();
82
		$this->realm = $defaults->getName();
83
	}
84
85
	/**
86
	 * Whether the user has initially authenticated via DAV