hasPDFExtension static method

bool hasPDFExtension(
  1. String filePath
)

Checks if the given file path has a PDF extension. Returns true if the file has a .pdf extension, otherwise false.

Implementation

static bool hasPDFExtension(String filePath) =>
    p.extension(filePath) == ".pdf";