@Override
    public OneTimeTokenAccount get(final long id) {
        return lock.tryLock(() -> {
            val accounts = readAccountsFromJsonRepository();
            return accounts.values()
                .stream()
                .flatMap(List::stream)
                .filter(ac -> ac.getId() == id)
                .findFirst()
                .map(this::decode)
                .orElse(null);
        });
    }
This is {@link JsonGoogleAuthenticatorTokenCredentialRepository}.

@author Misagh Moayyed
@since 5.1.0
support/cas-server-support-gauth-core/src/main/java/org/apereo/cas/gauth/credential/JsonGoogleAuthenticatorTokenCredentialRepository.java