Skip to content

Commit

Permalink
try solution #41
Browse files Browse the repository at this point in the history
Signed-off-by: Vincenzo Palazzo <vincenzopalazzodev@gmail.com>
  • Loading branch information
vincenzopalazzo committed May 3, 2021
1 parent d15fcd4 commit b554baf
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class GetUtxOutBtc(private val bitcoinRPC: LiteBitcoinRPC, private val alternati
// params.addParameter("include_mempool", true) TODO: double check
val getUtxo = bitcoinRPC.makeBitcoinRequest(params, UTXOBitcoin::class.java)
// TODO: bitcoin core should return an error?
if (getUtxo.amount == null || getUtxo.script == null) {
if (getUtxo.amount == null || getUtxo.script == null || getUtxo.script.hex == null || getUtxo.script.hex!!.isEmpty()) {
plugin.log(PluginLog.DEBUG, "GetUtxOutBtc: Received undefined response, return a null reponse")
response.apply {
add("amount", null)
Expand Down

0 comments on commit b554baf

Please sign in to comment.