[bisq-network/bisq] Add rpc method 'getfundingaddresses' (#4299)

dmos62 notifications at github.com
Tue Jun 16 11:07:43 UTC 2020


@dmos62 commented on this pull request.



> @@ -50,6 +75,68 @@ public long getAvailableBalance() {
         return balance.getValue();
     }
 
+    public long getAddressBalance(String addressString) {
+        Address address = getAddressEntry(addressString).getAddress();
+        return btcWalletService.getBalanceForAddress(address).value;
+    }
+
+    public String getFundingAddresses() {
+        if (!walletsManager.areWalletsAvailable())
+            throw new IllegalStateException("wallet is not yet available");
+
+        if (walletsManager.areWalletsEncrypted() && tempAesKey == null)
+            throw new IllegalStateException("wallet is locked");

Checks of this type will probably be performed for most API endpoints. It would be nice to eventually see them moved into their own methods (`checkThatWalletsAreAvailable()`, etc.). Not requesting this change at this point.

-- 
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/4299#pullrequestreview-431395433
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bisq.network/pipermail/bisq-github/attachments/20200616/d3b74ae8/attachment.html>


More information about the bisq-github mailing list