Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F13711255
D12631.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Subscribers
None
D12631.diff
View Options
diff --git a/web/cashtab/src/utils/__tests__/cashMethods.test.js b/web/cashtab/src/utils/__tests__/cashMethods.test.js
--- a/web/cashtab/src/utils/__tests__/cashMethods.test.js
+++ b/web/cashtab/src/utils/__tests__/cashMethods.test.js
@@ -271,6 +271,7 @@
);
const txBuilderResponse = signUtxosByAddress(
+ BCH,
mockSingleInputUtxo,
wallet,
outputObj,
@@ -338,6 +339,7 @@
);
const txBuilderResponse = signUtxosByAddress(
+ BCH,
mockSingleInputUtxo,
wallet,
outputObj,
diff --git a/web/cashtab/src/utils/cashMethods.js b/web/cashtab/src/utils/cashMethods.js
--- a/web/cashtab/src/utils/cashMethods.js
+++ b/web/cashtab/src/utils/cashMethods.js
@@ -152,7 +152,7 @@
return Bitcoin.ECPair.fromWIF(wif, xecBitcoinJSLib);
};
-export const signUtxosByAddress = (inputUtxos, wallet, txBuilder) => {
+export const signUtxosByAddress = (BCH, inputUtxos, wallet, txBuilder) => {
for (let i = 0; i < inputUtxos.length; i++) {
const utxo = inputUtxos[i];
const accounts = [wallet.Path245, wallet.Path145, wallet.Path1899];
@@ -161,7 +161,7 @@
.filter(acc => acc.cashAddress === utxo.address)
.pop().fundingWif;
- const utxoECPair = getECPairFromWIF(wif);
+ const utxoECPair = BCH.ECPair.fromWIF(wif);
txBuilder.sign(
i,
@@ -714,7 +714,7 @@
}
// Sign each XEC UTXO being consumed and refresh transactionBuilder
- txBuilder = signUtxosByAddress(inputUtxos, wallet, txBuilder);
+ txBuilder = signUtxosByAddress(BCH, inputUtxos, wallet, txBuilder);
let hex;
try {
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Apr 26, 11:11 (11 h, 2 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
5573374
Default Alt Text
D12631.diff (1 KB)
Attached To
D12631: [Cashtab] Temp revert local ecpair
Event Timeline
Log In to Comment