checkAvailableMethods method

  1. @override
Future<Map<String, bool>> checkAvailableMethods(
  1. List<SessionTypes> candidates
)
override

Implementation

@override
Future<Map<String, bool>> checkAvailableMethods(
    List<SessionTypes> candidates) async {
  var map = Map<String, bool>();

  if (candidates.contains(SessionTypes.APPLE)) {
    var appleAvailable = await TheAppleSignIn.isAvailable();
    map[SessionTypes.APPLE.getAsKey()] = appleAvailable;
  }

  if (candidates.contains(SessionTypes.GOOGLE)) {
    var googleAvailable = true;
    map[SessionTypes.GOOGLE.getAsKey()] = googleAvailable;
  }

  return map;
}