authToken method

  1. @override
Future<String?> authToken()
override

This method is used to get the Authentication Token.

Implementation

@override
Future<String?> authToken() async {
  String? registerResponse = FlyConstants.empty;
  try {
    registerResponse =
        await mirrorFlyMethodChannel.invokeMethod<String>('authtoken');
    LogMessage.d("authToken Result ", " $registerResponse");

    return registerResponse;
  } on PlatformException catch (e) {
    LogMessage.d("Platform Exception =", " $e");
    rethrow;
  } on Exception catch (error) {
    LogMessage.d("Exception ", " $error");
    rethrow;
  }
}