fix(mobile): better app state handling (#4989)

* fix(mobile): better app state handling

* watch -> read

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
This commit is contained in:
Fynn Petersen-Frey 2023-11-13 20:51:16 +01:00 committed by GitHub
parent 291159e7fc
commit 38983838fd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 63 additions and 61 deletions

View file

@ -274,7 +274,7 @@ class ManualUploadNotifier extends StateNotifier<ManualUploadState> {
// The app is currently in background. Perform the necessary cleanups which
// are on-hold for upload completion
if (appState != AppStateEnum.active && appState != AppStateEnum.resumed) {
ref.read(appStateProvider.notifier).handleAppInactivity();
ref.read(backupProvider.notifier).cancelBackup();
}
}