mirror of
https://github.com/Such-Software/hash-wallet.git
synced 2026-10-19 05:58:50 +02:00
Add passphrase support for Eth, Polygon, and Tron (#1719)
* Add passphrase support for Eth, Polygon, and Tron * move passphrase to advanced settings even for restore
This commit is contained in:
@@ -95,6 +95,7 @@ class CWNano extends Nano {
|
||||
String? password,
|
||||
String? mnemonic,
|
||||
String? parentAddress,
|
||||
String? passphrase,
|
||||
}) =>
|
||||
NanoNewWalletCredentials(
|
||||
name: name,
|
||||
@@ -102,6 +103,7 @@ class CWNano extends Nano {
|
||||
mnemonic: mnemonic,
|
||||
parentAddress: parentAddress,
|
||||
walletInfo: walletInfo,
|
||||
passphrase: passphrase,
|
||||
);
|
||||
|
||||
@override
|
||||
@@ -110,6 +112,7 @@ class CWNano extends Nano {
|
||||
required String password,
|
||||
required String mnemonic,
|
||||
required DerivationType derivationType,
|
||||
String? passphrase,
|
||||
}) {
|
||||
if (mnemonic.split(" ").length == 12 && derivationType != DerivationType.bip39) {
|
||||
throw Exception("Invalid mnemonic for derivation type!");
|
||||
@@ -120,6 +123,7 @@ class CWNano extends Nano {
|
||||
password: password,
|
||||
mnemonic: mnemonic,
|
||||
derivationType: derivationType,
|
||||
passphrase: passphrase,
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user