mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-12-23 03:59:23 +00:00
fix P2wpkhAddress btc ltc validation (#1749)
* fix P2wpkhAddress btc ltc validation * Update address_validator.dart
This commit is contained in:
parent
b56dcaca1c
commit
cb75f08b35
1 changed files with 2 additions and 2 deletions
|
@ -36,9 +36,9 @@ class AddressValidator extends TextValidator {
|
||||||
'|[0-9a-zA-Z]{105}|addr1[0-9a-zA-Z]{98}';
|
'|[0-9a-zA-Z]{105}|addr1[0-9a-zA-Z]{98}';
|
||||||
case CryptoCurrency.btc:
|
case CryptoCurrency.btc:
|
||||||
pattern =
|
pattern =
|
||||||
'${P2pkhAddress.regex.pattern}|${P2shAddress.regex.pattern}|${P2wpkhAddress.regex.pattern}|${P2trAddress.regex.pattern}|${P2wshAddress.regex.pattern}|${SilentPaymentAddress.regex.pattern}';
|
'${P2pkhAddress.regex.pattern}|${P2shAddress.regex.pattern}|${RegExp(r'(bc|tb)1q[ac-hj-np-z02-9]{25,39}}').pattern}|${P2trAddress.regex.pattern}|${P2wshAddress.regex.pattern}|${SilentPaymentAddress.regex.pattern}';
|
||||||
case CryptoCurrency.ltc:
|
case CryptoCurrency.ltc:
|
||||||
pattern = '^${P2wpkhAddress.regex.pattern}\$|^${MwebAddress.regex.pattern}\$';
|
pattern = '^${RegExp(r'ltc1q[ac-hj-np-z02-9]{25,39}').pattern}\$|^${MwebAddress.regex.pattern}\$';
|
||||||
case CryptoCurrency.nano:
|
case CryptoCurrency.nano:
|
||||||
pattern = '[0-9a-zA-Z_]+';
|
pattern = '[0-9a-zA-Z_]+';
|
||||||
case CryptoCurrency.banano:
|
case CryptoCurrency.banano:
|
||||||
|
|
Loading…
Reference in a new issue