safeCallLocalCache<T> method
Implementation
Future<Either<FetchFailure, T>> safeCallLocalCache<T>(T? response) async {
try {
if (response != null) {
return await right(response);
} else {
return await left(const FetchFailure.nothing());
}
} catch (e) {
return await left(const FetchFailure.nothing());
}
}