copyFileToAppDir static method

Future<File> copyFileToAppDir(
  1. String origin,
  2. String fileName
)

Implementation

static Future<File> copyFileToAppDir(String origin, String fileName) async {
  String destination = await getAppDirFilePath(fileName);

  await File(destination).create(recursive: true);
  return await File(origin).copy(destination);
}