bindPasskey static method Null safety

Future<BindPasskeyResponse> bindPasskey(
  1. String url
)

Bind a passkey to this device.

url URL used to bind a passkey to this device Returns a BindPasskeyResponse or throws an Exception

Implementation

static Future<BindPasskeyResponse> bindPasskey(String url) async {
  final Map<String, dynamic>? bindPasskeyResponse =
      await _channel.invokeMapMethod('bindPasskey', {'url': url});

  try {
    return BindPasskeyResponse(
      passkey: Passkey.mapToPasskey(bindPasskeyResponse?["passkey"]),
      postBindingRedirectUri: bindPasskeyResponse?["postBindingRedirectUri"],
    );
  } on Exception {
    rethrow;
  }
}