Skip to content

Commit

Permalink
specify precise backup attribute (prevent disabling it for everything))
Browse files Browse the repository at this point in the history
  • Loading branch information
MysticFragilist committed Feb 20, 2022
1 parent 59036bb commit 99382e1
Show file tree
Hide file tree
Showing 7 changed files with 309 additions and 120 deletions.
5 changes: 3 additions & 2 deletions android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,12 @@
</intent>
</queries>
<application
android:name="io.flutter.app.FlutterApplication"
android:name="${applicationName}"
android:label="ÉTS Mobile"
android:icon="@mipmap/launcher_icon"
android:usesCleartextTraffic="true"
android:allowBackup="false">
android:allowBackup="true"
android:fullBackupContent="@xml/backup_rules">
<activity
android:name=".MainActivity"
android:launchMode="singleTop"
Expand Down
4 changes: 4 additions & 0 deletions android/app/src/main/res/backup_rules.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<full-backup-content>
<exclude domain="sharedpref" path="FlutterSecureStorage"/>
</full-backup-content>
1 change: 1 addition & 0 deletions lib/core/managers/user_repository.dart
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,7 @@ class UserRepository {
return _info;
}

/// Check whether the user was previously authenticated.
Future<bool> wasPreviouslyLoggedIn() async {
try {
final String username = await _secureStorage.read(key: passwordSecureKey);
Expand Down
Loading

0 comments on commit 99382e1

Please sign in to comment.