Skip to content

Commit

Permalink
should work on all platforms
Browse files Browse the repository at this point in the history
  • Loading branch information
fossephate committed May 3, 2024
1 parent 3dea7ec commit 67a23b7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/view_model/auto_backup_view_model.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import 'package:cake_wallet/utils/alert_scheduler.dart';
import 'package:cake_wallet/view_model/backup_view_model.dart';
import 'package:flutter/foundation.dart';
import 'package:mobx/mobx.dart';
import 'package:path_provider/path_provider.dart';

part 'auto_backup_view_model.g.dart';

Expand Down Expand Up @@ -52,10 +53,9 @@ abstract class AutoBackupViewModelBase with Store {
if (backupDirPath.isEmpty) {
if (Platform.isAndroid) {
backupDirPath = "/storage/emulated/0/Documents/Cake Wallet/backups/";
} else if (Platform.isIOS){
backupDirPath = "/Documents/Cake Wallet/backups/";// CONFIRM THIS PATH
} else {
throw Exception("No backup directory set");
String path = (await getDownloadsDirectory())!.path;
backupDirPath = "$path/Cake Wallet/backups/";
}
}

Expand Down

0 comments on commit 67a23b7

Please sign in to comment.