@bitgo-beta/utxo-lib
Advanced tools
Comparing version 2.4.2-beta.148 to 2.4.2-beta.149
@@ -176,2 +176,3 @@ "use strict"; | ||
case networks_1.networks.bitcoingold: | ||
case networks_1.networks.ecash: | ||
return bitcoinjs_lib_1.Transaction.SIGHASH_ALL | UtxoTransaction_1.UtxoTransaction.SIGHASH_FORKID; | ||
@@ -222,2 +223,2 @@ default: | ||
exports.signInput2Of3 = signInput2Of3; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2lnbmF0dXJlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vc3JjL2JpdGdvL3NpZ25hdHVyZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7QUFFQSxpREFBZ0Y7QUFFaEYsdURBQW9EO0FBRXBELG1EQU15QjtBQUV6QiwwQ0FBNEQ7QUFDNUQsNENBQTZDO0FBQzdDLDZDQUF3RDtBQThCeEQ7Ozs7Ozs7OztHQVNHO0FBQ0gsU0FBZ0IseUJBQXlCLENBQ3ZDLFdBQXFDLEVBQ3JDLFVBQWtCLEVBQ2xCLE1BQWUsRUFDZix1QkFBNkMsRUFBRSxFQUMvQyxXQUFpQztJQUVqQywwQkFBMEI7SUFDMUIsSUFBSSxDQUFDLFdBQVcsQ0FBQyxHQUFHLEVBQUU7UUFDcEIsTUFBTSxJQUFJLEtBQUssQ0FBQyxxQkFBcUIsQ0FBQyxDQUFDO0tBQ3hDO0lBRUQsTUFBTSxLQUFLLEdBQUcsV0FBVyxDQUFDLEdBQUcsQ0FBQyxVQUFVLENBQUMsQ0FBQztJQUMxQywwQkFBMEI7SUFDMUIsSUFBSSxDQUFDLEtBQUssRUFBRTtRQUNWLE1BQU0sSUFBSSxLQUFLLENBQUMscUJBQXFCLFVBQVUsRUFBRSxDQUFDLENBQUM7S0FDcEQ7SUFFRCxJQUFJLENBQUMsQ0FBQyxLQUFLLENBQUMsTUFBTSx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1xufVxuIl19 |
@@ -40,2 +40,3 @@ "use strict"; | ||
case networks_1.networks.dogecoin: | ||
case networks_1.networks.ecash: | ||
case networks_1.networks.litecoin: | ||
@@ -63,2 +64,3 @@ return UtxoPsbt_1.UtxoPsbt.fromBuffer(buf, { network, bip32PathsAbsolute }); | ||
case networks_1.networks.dogecoin: | ||
case networks_1.networks.ecash: | ||
case networks_1.networks.litecoin: | ||
@@ -85,2 +87,3 @@ return UtxoPsbt_1.UtxoPsbt.fromTransaction(tx, prevOuts); | ||
case networks_1.networks.bitcoingold: | ||
case networks_1.networks.ecash: | ||
return 2; | ||
@@ -99,2 +102,3 @@ case networks_1.networks.zcash: | ||
case networks_1.networks.bitcoingold: | ||
case networks_1.networks.ecash: | ||
if (version !== 2) { | ||
@@ -120,2 +124,3 @@ throw new Error(`invalid version`); | ||
case networks_1.networks.bitcoingold: | ||
case networks_1.networks.ecash: | ||
if (version !== 2) { | ||
@@ -153,2 +158,3 @@ throw new Error(`invalid version`); | ||
case networks_1.networks.dogecoin: | ||
case networks_1.networks.ecash: | ||
case networks_1.networks.litecoin: { | ||
@@ -218,2 +224,2 @@ psbt = UtxoPsbt_1.UtxoPsbt.createPsbt(psbtOpts); | ||
exports.createTransactionBuilderFromTransaction = createTransactionBuilderFromTransaction; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidHJhbnNhY3Rpb24uanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9zcmMvYml0Z28vdHJhbnNhY3Rpb24udHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7O0FBRUEsMENBQTREO0FBRTVELHlDQUFnRDtBQUNoRCx1REFBb0Q7QUFDcEQscUVBQWtFO0FBQ2xFLDhDQUEyQztBQUMzQyw0REFBeUQ7QUFDekQsMEVBQXVFO0FBQ3ZFLGlEQUE4QztBQUM5Qyw2RUFBMEU7QUFDMUUsK0RBQTBFO0FBRTFFLFN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bmRlZmluZWQsXG4gICAgICAgIHByZXZPdXRwdXRzIGFzIFR4T3V0cHV0PFROdW1iZXI+W11cbiAgICAgICk7XG4gIH1cblxuICB0aHJvdyBuZXcgRXJyb3IoYGludmFsaWQgbmV0d29ya2ApO1xufVxuIl19 |
{ | ||
"name": "@bitgo-beta/utxo-lib", | ||
"version": "2.4.2-beta.148", | ||
"version": "2.4.2-beta.149", | ||
"description": "Client-side Bitcoin JavaScript library", | ||
@@ -49,3 +49,3 @@ "main": "./dist/src/index.js", | ||
"dependencies": { | ||
"@bitgo-beta/blake2b": "3.0.4-beta.148", | ||
"@bitgo-beta/blake2b": "3.0.4-beta.149", | ||
"@noble/secp256k1": "1.6.3", | ||
@@ -87,3 +87,3 @@ "bech32": "^2.0.0", | ||
"license": "MIT", | ||
"gitHead": "3e2f6405801b0e5f51f824edbad4cf596df682ab" | ||
"gitHead": "177879f8783e8a7af3b8d5eb1d38dd9b18392880" | ||
} |
@@ -55,2 +55,3 @@ # BitGo UTXO library | ||
|Dash|`utxolib.networks.dash`|`utxolib.networks.dash`| | ||
|eCash|`utxolib.networks.ecash`|`utxolib.networks.ecashTestnet`| | ||
|Litecoin|`utxolib.networks.litecoin`|`utxolib.networks.litecoinTest`| | ||
@@ -57,0 +58,0 @@ |Zcash|`utxolib.networks.zcash`|`utxolib.networks.zcashTest`| |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
1127427
8821
60
+ Added@bitgo-beta/blake2b@3.0.4-beta.149(transitive)
+ Added@bitgo-beta/blake2b-wasm@3.0.4-beta.149(transitive)
- Removed@bitgo-beta/blake2b@3.0.4-beta.148(transitive)
- Removed@bitgo-beta/blake2b-wasm@3.0.4-beta.148(transitive)