diff --git a/lib/core/sync/background_sync.dart b/lib/core/sync/background_sync.dart index 1c7ce0a..d4c8304 100644 --- a/lib/core/sync/background_sync.dart +++ b/lib/core/sync/background_sync.dart @@ -38,7 +38,7 @@ Future registerBackgroundSync() async { _kTaskName, frequency: const Duration(minutes: 15), constraints: Constraints(networkType: NetworkType.connected), - existingWorkPolicy: ExistingWorkPolicy.keep, + existingWorkPolicy: ExistingPeriodicWorkPolicy.keep, ); } diff --git a/pubspec.yaml b/pubspec.yaml index 00a178c..77b514b 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -47,7 +47,7 @@ dependencies: # Background sync and local notifications flutter_local_notifications: ^18.0.1 - workmanager: ^0.5.2 + workmanager: ^0.9.0 dev_dependencies: flutter_test: