mirror of
https://github.com/comit-network/xmr-btc-swap.git
synced 2025-08-25 06:39:53 -04:00
fix(gui): Accept integrated Monero addresses
This commit is contained in:
parent
9ddf2daafe
commit
75f37a987b
1 changed files with 2 additions and 2 deletions
|
@ -17,8 +17,8 @@ export function piconerosToXmr(piconeros: number): number {
|
|||
|
||||
export function isXmrAddressValid(address: string, stagenet: boolean) {
|
||||
const re = stagenet
|
||||
? "[57][0-9AB][1-9A-HJ-NP-Za-km-z]{93}"
|
||||
: "[48][0-9AB][1-9A-HJ-NP-Za-km-z]{93}";
|
||||
? "^(5[0-9A-Za-z]{94}|5[0-9A-Za-z]{105})$"
|
||||
: "^(?:[48][0-9A-Za-z]{94}|4[0-9A-Za-z]{105})$";
|
||||
return new RegExp(`(?:^${re}$)`).test(address);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue