mirror of
https://gitlab.com/famedly/fluffychat.git
synced 2024-11-24 04:59:26 +01:00
fix: download path for saving files
This commit is contained in:
parent
bda4727490
commit
967f64247e
@ -15,7 +15,7 @@ extension MatrixFileExtension on MatrixFile {
|
|||||||
final fileName = name.split('/').last;
|
final fileName = name.split('/').last;
|
||||||
if (PlatformInfos.isMobile) {
|
if (PlatformInfos.isMobile) {
|
||||||
final tmpDirectory = PlatformInfos.isAndroid
|
final tmpDirectory = PlatformInfos.isAndroid
|
||||||
? Directory('/storage/emulated/0/Download')
|
? Directory('/storage/emulated/0/Download/')
|
||||||
: await getTemporaryDirectory();
|
: await getTemporaryDirectory();
|
||||||
final path = '${tmpDirectory.path}$fileName';
|
final path = '${tmpDirectory.path}$fileName';
|
||||||
await File(path).writeAsBytes(bytes);
|
await File(path).writeAsBytes(bytes);
|
||||||
|
Loading…
Reference in New Issue
Block a user