X-Git-Url: https://git.ktnx.net/?p=mobile-ledger.git;a=blobdiff_plain;f=app%2Fsrc%2Fmain%2Fjava%2Fnet%2Fktnx%2Fmobileledger%2Fmodel%2FData.java;h=48555ff0102c3bf07e00d000ff9492915e730f83;hp=1fc4aa06a8962e1c07bf225e3024ee48a8a83518;hb=55f76739da51795c0258fb17a687219e81280d04;hpb=73adeb59bc035a88a2c18d8cd79467e2f15825db diff --git a/app/src/main/java/net/ktnx/mobileledger/model/Data.java b/app/src/main/java/net/ktnx/mobileledger/model/Data.java index 1fc4aa06..48555ff0 100644 --- a/app/src/main/java/net/ktnx/mobileledger/model/Data.java +++ b/app/src/main/java/net/ktnx/mobileledger/model/Data.java @@ -29,8 +29,7 @@ import java.util.List; public final class Data { public static ObservableList transactions = new ObservableList<>(new ArrayList<>()); - public static ObservableList accounts = - new ObservableList<>(new ArrayList<>()); + public static ObservableList accounts = new ObservableList<>(new ArrayList<>()); public static ObservableAtomicInteger backgroundTaskCount = new ObservableAtomicInteger(0); public static ObservableValue lastUpdateDate = new ObservableValue<>(); public static ObservableValue profile = new ObservableValue<>(); @@ -42,7 +41,7 @@ public final class Data { profile.set(newProfile); } public static int getProfileIndex(MobileLedgerProfile profile) { - try(LockHolder lh = profiles.lockForReading()) { + try (LockHolder lh = profiles.lockForReading()) { for (int i = 0; i < profiles.size(); i++) { MobileLedgerProfile p = profiles.get(i); if (p.equals(profile)) return i;