checkAvailability method

Future<String> checkAvailability(
  1. Datum content
)

Implementation

Future<String> checkAvailability(contentmodel.Datum content) async {
  SharedPreferences sharedPreferences = await DeviceStorage().getInstance();
  String model = await getAvailabilityModel(content, sharedPreferences);
  if (model.isEmpty) {
    await sharedPreferences.setString(DeviceStorage.availabilityData, "");
    model = await getAvailabilityModel(content, sharedPreferences);
  }
  return model;
}