diff --git a/lib/services/transaction/index.js b/lib/services/transaction/index.js index 0953853d..9f327d31 100644 --- a/lib/services/transaction/index.js +++ b/lib/services/transaction/index.js @@ -307,11 +307,18 @@ TransactionService.prototype._getInputValues = function(tx, options, callback) { }, // if not in mempool or tx index, we just don't have it, yet? function(txid, tx, next) { + if (!tx) { - return next(new Error('Transaction Service: prev transacion: (' + input.prevout.txid() + ') for tx: ' + + log.info('Transaction Service: prev transacion: (' + input.prevout.txid() + ') for tx: ' + _tx.txid() + ' at input index: ' + outputIndex + ' is missing from the index or not in the memory pool. It could be' + - ' that the parent tx has not yet been relayed to us, but will be relayed in the near future.')); + ' that the parent tx has not yet been relayed to us, but will be relayed in the near future.'); + return; + /* FLOsight Error Resolution by RanchiMall 11th May 2021 + return next(new Error('Transaction Service: prev transacion: (' + input.prevout.txid() + ') for tx: ' + + _tx.txid() + ' at input index: ' + outputIndex + ' is missing from the index or not in the memory pool. It could be' + + ' that the parent tx has not yet been relayed to us, but will be relayed in the near future.'));*/ } + var output = tx.outputs[outputIndex]; assert(output, 'Expected an output, but did not get one for tx: ' + tx.txid() + ' outputIndex: ' + outputIndex);