fix possible npe on connection changed

This commit is contained in:
woodser 2023-07-09 07:09:59 -04:00
parent ff9f0a7204
commit 079944c934

View File

@ -498,7 +498,7 @@ public final class CoreMoneroConnectionsService {
daemon = null;
connectionList.setCurrentConnectionUri(null);
} else {
daemon = new MoneroDaemonRpc(connectionManager.getConnection());
daemon = new MoneroDaemonRpc(currentConnection);
connectionList.removeConnection(currentConnection.getUri());
connectionList.addConnection(currentConnection);
connectionList.setCurrentConnectionUri(currentConnection.getUri());