Improve method name, add comment

This commit is contained in:
Manfred Karrer 2018-11-12 20:16:55 -05:00
parent cf46f0b06a
commit a65f1df5c8
No known key found for this signature in database
GPG key ID: 401250966A6B2C46

View file

@ -115,7 +115,8 @@ public class TxOutputParser {
// The LOCKUP BSQ is burnt unless the output exactly matches the input, that would cause the // The LOCKUP BSQ is burnt unless the output exactly matches the input, that would cause the
// output to not be BSQ output at all // output to not be BSQ output at all
handleUnlockBondTx(tempTxOutput); handleUnlockBondTx(tempTxOutput);
} else if (isBurnFeeTxOutput(tempTxOutput)) { } else if (isBtcOutputOfBurnFeeTx(tempTxOutput)) {
// In case we have the opReturn for a burn fee tx all outputs after 1st output are considered BTC
handleBtcOutput(tempTxOutput, index); handleBtcOutput(tempTxOutput, index);
} else if (availableInputValue > 0 && availableInputValue >= txOutputValue) { } else if (availableInputValue > 0 && availableInputValue >= txOutputValue) {
handleBsqOutput(tempTxOutput, index, txOutputValue); handleBsqOutput(tempTxOutput, index, txOutputValue);
@ -172,7 +173,7 @@ public class TxOutputParser {
bsqOutputFound = true; bsqOutputFound = true;
} }
private boolean isBurnFeeTxOutput(TempTxOutput tempTxOutput) { private boolean isBtcOutputOfBurnFeeTx(TempTxOutput tempTxOutput) {
// If we get a asset listing or proof of burn tx we have only 1 BSQ output and if the // If we get a asset listing or proof of burn tx we have only 1 BSQ output and if the
// burned amount is larger than the miner fee we might have a BTC output for receiving the burned funds. // burned amount is larger than the miner fee we might have a BTC output for receiving the burned funds.
// If the burned funds are less than the miner fee a BTC input is used for miner fee and a BTC change output for // If the burned funds are less than the miner fee a BTC input is used for miner fee and a BTC change output for