diff --git a/lib/screen/pages/files/fileDownload.dart b/lib/screen/pages/files/fileDownload.dart index e600ab9..0ed9a65 100644 --- a/lib/screen/pages/files/fileDownload.dart +++ b/lib/screen/pages/files/fileDownload.dart @@ -20,9 +20,9 @@ class _FileDownloadState extends State { late DownloaderCore core; void download(String remotePath, String name) async { - List? paths = await getExternalStorageDirectories(type: StorageDirectory.downloads); + Directory paths = await getApplicationDocumentsDirectory(); - String local = paths!.first.path + Platform.pathSeparator + name; + String local = paths.path + Platform.pathSeparator + name; DownloaderUtils options = DownloaderUtils( progressCallback: (current, total) {