loadScram static method

Future<ScramCredential?> loadScram({
  1. required String realmUri,
  2. required String authId,
})

Implementation

static Future<ScramCredential?> loadScram({
  required String realmUri,
  required String authId,
}) async {
  final repo = _provider;
  if (repo == null) {
    return null;
  }
  try {
    final credential = await repo.loadScram(
      realmUri: realmUri,
      authId: authId,
    );
    _emit(
      method: 'scram',
      realmUri: realmUri,
      authId: authId,
      hit: credential != null,
    );
    return credential;
  } on CredentialRejection catch (rejection) {
    _emit(
      method: 'scram',
      realmUri: realmUri,
      authId: authId,
      hit: false,
      rejection: rejection,
    );
    rethrow;
  }
}