mirror of
https://github.com/sparrowwallet/sparrow.git
synced 2026-08-11 09:08:02 +00:00
handle npe connecting to bitcoin core with wallet functionality disabled
This commit is contained in:
@@ -149,6 +149,9 @@ public class BitcoindClient {
|
||||
List<String> loadedWallets;
|
||||
try {
|
||||
loadedWallets = getBitcoindService().listWallets();
|
||||
if(loadedWallets == null) {
|
||||
throw new BitcoinRPCException("Wallet support must be enabled in Bitcoin Core");
|
||||
}
|
||||
legacyWalletExists = loadedWallets.contains(Bwt.DEFAULT_CORE_WALLET);
|
||||
} catch(JsonRpcException e) {
|
||||
if(e.getErrorMessage().getCode() == RPC_METHOD_NOT_FOUND) {
|
||||
|
||||
Reference in New Issue
Block a user