From c4a7b68048d389cac3c68797ce4a44bca7979d17 Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Tue, 2 Jan 2024 15:18:58 -0800 Subject: liquid payments --- src/lib/utils.js | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'src/lib') diff --git a/src/lib/utils.js b/src/lib/utils.js index 9dbdc2ab..738413bf 100644 --- a/src/lib/utils.js +++ b/src/lib/utils.js @@ -287,3 +287,17 @@ export let closest = (a, n) => a.reduce((prev, curr) => Math.abs(curr - n) < Math.abs(prev - n) ? curr : prev ); + +export let isLiquid = (text) => + text.startsWith("Az") || + text.startsWith("lq1") || + text.startsWith("VJL") || + text.startsWith("VT") || + text.startsWith("XR") || + text.startsWith("XC") || + ((text.startsWith("H") || text.startsWith("G") || text.startsWith("Q")) && + text.length === 34) || + (text.startsWith("ert1q") && text.length === 43) || + (text.startsWith("ex1q") && text.length === 42) || + text.startsWith("el1qq") || + text.startsWith("lq1qq"); -- cgit v1.2.3