[bisq-network/bisq] PaymentAccount object removal from ObservableSet issue (#3572)

chimp1984 notifications at github.com
Tue Nov 12 05:14:19 UTC 2019


After further investigation it seems that ObservableSet behaves weird. If you copy the ObservableSet entries into a HashSet you can remove it.

```
   public void removePaymentAccount(PaymentAccount paymentAccount) {
        HashSet<PaymentAccount> temp = new HashSet<>(paymentAccountsAsObservable);
        boolean changed = temp.remove(paymentAccount);
        paymentAccountsAsObservable.clear();
        paymentAccountsAsObservable.addAll(temp);
        if (changed)
            persist();
    }
```

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/bisq-network/bisq/pull/3572#issuecomment-552737414
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bisq.network/pipermail/bisq-github/attachments/20191111/f2126494/attachment-0001.html>


More information about the bisq-github mailing list