getExpiry method

Future<String> getExpiry()

Implementation

Future<String> getExpiry() async {
  try {
    final prefs = await SharedPreferences.getInstance();
    var exp = prefs.getString(prefixExpiry);

    if (exp == null) throw ("Expiry not found");

    return exp;
  } catch (e) {
    // print(e);
    throw (e);
  }
}