From 92faa342ad0a187cd322ebc4f2a5a6743e85c316 Mon Sep 17 00:00:00 2001 From: tobiasKaminsky Date: Tue, 22 Oct 2024 07:44:29 +0200 Subject: [PATCH] sync only on wifi Signed-off-by: tobiasKaminsky --- .../java/com/nextcloud/client/jobs/InternalTwoWaySyncWork.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/com/nextcloud/client/jobs/InternalTwoWaySyncWork.kt b/app/src/main/java/com/nextcloud/client/jobs/InternalTwoWaySyncWork.kt index a843316852..a29c9ecdfd 100644 --- a/app/src/main/java/com/nextcloud/client/jobs/InternalTwoWaySyncWork.kt +++ b/app/src/main/java/com/nextcloud/client/jobs/InternalTwoWaySyncWork.kt @@ -35,7 +35,9 @@ class InternalTwoWaySyncWork( var result = true if (powerManagementService.isPowerSavingEnabled || - !connectivityService.isConnected || connectivityService.isInternetWalled + !connectivityService.isConnected || + connectivityService.isInternetWalled || + !connectivityService.connectivity.isWifi ) { Log_OC.d(TAG, "Not starting due to constraints!") return Result.success()