-
Notifications
You must be signed in to change notification settings - Fork 69
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix decodeRawTransaction network addresses #359
Conversation
b536229
to
daf7704
Compare
daf7704
to
453e996
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, could you change target to dev?
const { hex, fee } = await this._buildTransaction(transactions, feePerByte) | ||
await this.getMethod('sendRawTransaction')(hex) | ||
return normalizeTransactionObject(decodeRawTransaction(hex), fee) | ||
return normalizeTransactionObject(decodeRawTransaction(hex, network), fee) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would be clearer to just pass this._network
here and avoid the reassignment
@@ -56,12 +57,14 @@ export default superclass => class BitcoinWalletProvider extends superclass { | |||
} | |||
|
|||
async sendSweepTransaction (externalChangeAddress, feePerByte, outputs, fixedInputs) { | |||
const network = this._network |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
} | ||
|
||
async updateTransactionFee (tx, newFeePerByte) { | ||
const network = this._network |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
@@ -237,6 +240,7 @@ export default superclass => class BitcoinWalletProvider extends superclass { | |||
} | |||
|
|||
async getInputsForAmount (_targets = [], _feePerByte, fixedInputs = [], numAddressPerCall = 100, sweep = false) { | |||
const network = this._network |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
Good point @monokh. Updated to use |
Description
This PR fixes decodeRawTransaction network addresses.
Submission Checklist 📝
decodeRawTransaction
is passed network