From 401c522d57de54644de32a1831e1efa9608eec7b Mon Sep 17 00:00:00 2001 From: Damyan Ivanov Date: Thu, 7 Mar 2019 06:58:43 +0200 Subject: [PATCH] try{} needs to be immediately after incrementing the background task count --- .../java/net/ktnx/mobileledger/async/UpdateAccountsTask.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/net/ktnx/mobileledger/async/UpdateAccountsTask.java b/app/src/main/java/net/ktnx/mobileledger/async/UpdateAccountsTask.java index cff03a28..64a5559a 100644 --- a/app/src/main/java/net/ktnx/mobileledger/async/UpdateAccountsTask.java +++ b/app/src/main/java/net/ktnx/mobileledger/async/UpdateAccountsTask.java @@ -31,9 +31,9 @@ import java.util.ArrayList; public class UpdateAccountsTask extends AsyncTask> { protected ArrayList doInBackground(Void... params) { Data.backgroundTaskCount.incrementAndGet(); - String profileUUID = Data.profile.get().getUuid(); - boolean onlyStarred = Data.optShowOnlyStarred.get(); try { + String profileUUID = Data.profile.get().getUuid(); + boolean onlyStarred = Data.optShowOnlyStarred.get(); ArrayList newList = new ArrayList<>(); String sql = "SELECT name, hidden FROM accounts WHERE profile = ?"; -- 2.39.5