From e949b51ca8fedb856e3b2721691dac4c4e5a1122 Mon Sep 17 00:00:00 2001 From: 4sterisk <4sterisk@ymail.ne.jp> Date: Wed, 18 Dec 2024 06:28:45 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20iOS=E3=81=A7=E7=94=BB=E5=83=8F=E4=BF=9D?= =?UTF-8?q?=E5=AD=98=E6=99=82=E3=81=AB=E3=83=91=E3=83=BC=E3=83=9F=E3=83=83?= =?UTF-8?q?=E3=82=B7=E3=83=A7=E3=83=B3=E8=A8=B1=E5=8F=AF=E3=81=8C=E8=A1=A8?= =?UTF-8?q?=E7=A4=BA=E3=81=95=E3=82=8C=E3=81=AA=E3=81=84=E3=81=AE=E3=82=92?= =?UTF-8?q?=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/state_notifier/common/download_file_notifier.dart | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/state_notifier/common/download_file_notifier.dart b/lib/state_notifier/common/download_file_notifier.dart index b4c4db7d5..0e8df2951 100644 --- a/lib/state_notifier/common/download_file_notifier.dart +++ b/lib/state_notifier/common/download_file_notifier.dart @@ -44,7 +44,10 @@ class DownloadFileNotifier extends _$DownloadFileNotifier { } else if (defaultTargetPlatform == TargetPlatform.iOS) { final permissionStatus = await Permission.photosAddOnly.status; if (!permissionStatus.isGranted) { - return DownloadFileResult.permissionDenied; + final p = await Permission.photosAddOnly.request(); + if (!p.isGranted) { + return DownloadFileResult.permissionDenied; + } } }