From 6bb99f2ae47231b0665a7bb457d2ed67b6ae1356 Mon Sep 17 00:00:00 2001 From: Felix Ableitner Date: Sun, 26 Oct 2014 02:17:12 +0300 Subject: [PATCH] Fix device sync percentage (fixes #161). --- .../java/com/nutomic/syncthingandroid/syncthing/RestApi.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/com/nutomic/syncthingandroid/syncthing/RestApi.java b/src/main/java/com/nutomic/syncthingandroid/syncthing/RestApi.java index a951b6bf..e7e7e95c 100644 --- a/src/main/java/com/nutomic/syncthingandroid/syncthing/RestApi.java +++ b/src/main/java/com/nutomic/syncthingandroid/syncthing/RestApi.java @@ -612,7 +612,7 @@ public class RestApi implements SyncthingService.OnWebGuiAvailableListener, } if (isShared) { long global = mCachedModelInfo.get(id).globalBytes; - long local = mCachedModelInfo.get(id).localBytes; + long local = mCachedModelInfo.get(id).inSyncBytes; percentageSum += (global != 0) ? (local * 100f) / global : 100f;