mirror of
https://github.com/bitcoinj/bitcoinj.git
synced 2024-11-19 09:50:32 +01:00
Initiliaze/assign sendResult. Prevents NullPointerException and app from crashing when sending money out.
This commit is contained in:
parent
0ed260bae2
commit
7ffe2a6360
@ -36,7 +36,7 @@ public class SendMoneyController {
|
||||
try {
|
||||
Address destination = new Address(Main.params, address.getText());
|
||||
Wallet.SendRequest req = Wallet.SendRequest.emptyWallet(destination);
|
||||
Main.bitcoin.wallet().sendCoins(req);
|
||||
sendResult = Main.bitcoin.wallet().sendCoins(req);
|
||||
Futures.addCallback(sendResult.broadcastComplete, new FutureCallback<Transaction>() {
|
||||
@Override
|
||||
public void onSuccess(Transaction result) {
|
||||
|
Loading…
Reference in New Issue
Block a user