isCached static method

Future<bool> isCached(
  1. String url
)

Checks if a PDF is cached for the given URL

Implementation

static Future<bool> isCached(String url) async {
  try {
    final file = await _getCacheFile(url);
    return await file.exists();
  } catch (e) {
    return false;
  }
}