Code Duplication    Length = 3-3 lines in 2 locations

src/Authentication/JWTAuthenticationHandler.php 1 location

@@ 54-56 (lines=3) @@
51
        // Get the default user currently logged in via a different way, could be BasicAuth/normal login
52
        $member = Security::getCurrentUser();
53
54
        if (!empty($matches[1])) {
55
            // Validate the token. This is critical for security
56
            $member = $this->authenticator->authenticate(['token' => $matches[1]], $request);
57
        }
58
59
        if ($member) {

src/Mutations/RefreshTokenMutationCreator.php 1 location

@@ 55-57 (lines=3) @@
52
        $result = new ValidationResult();
53
        $matches = HeaderExtractor::getAuthorizationHeader($request);
54
55
        if (!empty($matches[1])) {
56
            $member = $authenticator->authenticate(['token' => $matches[1]], $request, $result);
57
        }
58
59
        $expired = false;
60
        // If we have a valid member, or there are no matches, there's no reason to go in here