mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-01-22 18:44:31 +00:00
partial derivation not found null fix
This commit is contained in:
parent
d97c208135
commit
0cace4d7bc
6 changed files with 90 additions and 0 deletions
|
@ -2720,6 +2720,21 @@ class BitcoinWallet extends CoinServiceAPI
|
|||
}
|
||||
}
|
||||
|
||||
if (wif == null || pubKey == null) {
|
||||
final address = await db.getAddress(walletId, sd.utxo.address!);
|
||||
if (address?.derivationPath != null) {
|
||||
final node = await Bip32Utils.getBip32Node(
|
||||
(await mnemonicString)!,
|
||||
(await mnemonicPassphrase)!,
|
||||
_network,
|
||||
address!.derivationPath!.value,
|
||||
);
|
||||
|
||||
wif = node.toWIF();
|
||||
pubKey = Format.uint8listToString(node.publicKey);
|
||||
}
|
||||
}
|
||||
|
||||
if (wif != null && pubKey != null) {
|
||||
final PaymentData data;
|
||||
final Uint8List? redeemScript;
|
||||
|
|
|
@ -2485,6 +2485,21 @@ class DogecoinWallet extends CoinServiceAPI
|
|||
}
|
||||
}
|
||||
|
||||
if (wif == null || pubKey == null) {
|
||||
final address = await db.getAddress(walletId, sd.utxo.address!);
|
||||
if (address?.derivationPath != null) {
|
||||
final node = await Bip32Utils.getBip32Node(
|
||||
(await mnemonicString)!,
|
||||
(await mnemonicPassphrase)!,
|
||||
network,
|
||||
address!.derivationPath!.value,
|
||||
);
|
||||
|
||||
wif = node.toWIF();
|
||||
pubKey = Format.uint8listToString(node.publicKey);
|
||||
}
|
||||
}
|
||||
|
||||
if (wif != null && pubKey != null) {
|
||||
final PaymentData data;
|
||||
final Uint8List? redeemScript;
|
||||
|
|
|
@ -1711,6 +1711,21 @@ class FiroWallet extends CoinServiceAPI with WalletCache, WalletDB, FiroHive {
|
|||
}
|
||||
}
|
||||
|
||||
if (wif == null || pubKey == null) {
|
||||
final address = await db.getAddress(walletId, sd.utxo.address!);
|
||||
if (address?.derivationPath != null) {
|
||||
final node = await Bip32Utils.getBip32Node(
|
||||
(await mnemonicString)!,
|
||||
(await mnemonicPassphrase)!,
|
||||
_network,
|
||||
address!.derivationPath!.value,
|
||||
);
|
||||
|
||||
wif = node.toWIF();
|
||||
pubKey = Format.uint8listToString(node.publicKey);
|
||||
}
|
||||
}
|
||||
|
||||
if (wif != null && pubKey != null) {
|
||||
final PaymentData data;
|
||||
final Uint8List? redeemScript;
|
||||
|
|
|
@ -2660,6 +2660,21 @@ class LitecoinWallet extends CoinServiceAPI
|
|||
}
|
||||
}
|
||||
|
||||
if (wif == null || pubKey == null) {
|
||||
final address = await db.getAddress(walletId, sd.utxo.address!);
|
||||
if (address?.derivationPath != null) {
|
||||
final node = await Bip32Utils.getBip32Node(
|
||||
(await mnemonicString)!,
|
||||
(await mnemonicPassphrase)!,
|
||||
_network,
|
||||
address!.derivationPath!.value,
|
||||
);
|
||||
|
||||
wif = node.toWIF();
|
||||
pubKey = Format.uint8listToString(node.publicKey);
|
||||
}
|
||||
}
|
||||
|
||||
if (wif != null && pubKey != null) {
|
||||
final PaymentData data;
|
||||
final Uint8List? redeemScript;
|
||||
|
|
|
@ -2653,6 +2653,21 @@ class NamecoinWallet extends CoinServiceAPI
|
|||
}
|
||||
}
|
||||
|
||||
if (wif == null || pubKey == null) {
|
||||
final address = await db.getAddress(walletId, sd.utxo.address!);
|
||||
if (address?.derivationPath != null) {
|
||||
final node = await Bip32Utils.getBip32Node(
|
||||
(await mnemonicString)!,
|
||||
(await mnemonicPassphrase)!,
|
||||
_network,
|
||||
address!.derivationPath!.value,
|
||||
);
|
||||
|
||||
wif = node.toWIF();
|
||||
pubKey = Format.uint8listToString(node.publicKey);
|
||||
}
|
||||
}
|
||||
|
||||
if (wif != null && pubKey != null) {
|
||||
final PaymentData data;
|
||||
final Uint8List? redeemScript;
|
||||
|
|
|
@ -2814,6 +2814,21 @@ class ParticlWallet extends CoinServiceAPI
|
|||
}
|
||||
}
|
||||
|
||||
if (wif == null || pubKey == null) {
|
||||
final address = await db.getAddress(walletId, sd.utxo.address!);
|
||||
if (address?.derivationPath != null) {
|
||||
final node = await Bip32Utils.getBip32Node(
|
||||
(await mnemonicString)!,
|
||||
(await mnemonicPassphrase)!,
|
||||
_network,
|
||||
address!.derivationPath!.value,
|
||||
);
|
||||
|
||||
wif = node.toWIF();
|
||||
pubKey = Format.uint8listToString(node.publicKey);
|
||||
}
|
||||
}
|
||||
|
||||
if (wif != null && pubKey != null) {
|
||||
final PaymentData data;
|
||||
final Uint8List? redeemScript;
|
||||
|
|
Loading…
Reference in a new issue