init method

Future<void> init()

Implementation

Future<void> init() async {
  if (_wastInited) return;
  if (Platform.isIOS) throw "IOS is not soported";
  reader = (Platform.isAndroid) ? _SharedPreferences() : _LocalServer();
  try {
    await reader.init();
    await Future.delayed(const Duration(seconds: 1));
    _wastInited = true;
  } catch (err) {
    if (kDebugMode) print("ManagerSDKF.init EROR: ${err.toString()}");
    throw '''Servicio de autentificación no encontrado''';
  }
}