mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2025-10-10 15:53:10 +02:00
enable autopay, change parsing
This commit is contained in:
@@ -71,7 +71,7 @@ fun CashuPreview(cashutoken: String, accountViewModel: AccountViewModel) {
|
|||||||
.padding(vertical = 10.dp),
|
.padding(vertical = 10.dp),
|
||||||
onClick = {
|
onClick = {
|
||||||
runCatching {
|
runCatching {
|
||||||
val url = "https://redeem.cashu.me?token=$cashutoken&lightning=$lnaddress"
|
val url = "https://redeem.cashu.me?token=$cashutoken&lightning=$lnaddress&autopay=true"
|
||||||
val intent = Intent(Intent.ACTION_VIEW, Uri.parse(url))
|
val intent = Intent(Intent.ACTION_VIEW, Uri.parse(url))
|
||||||
startActivity(context, intent, null)
|
startActivity(context, intent, null)
|
||||||
}
|
}
|
||||||
|
@@ -284,7 +284,7 @@ private fun RenderWord(
|
|||||||
WordType.INVOICE
|
WordType.INVOICE
|
||||||
} else if (word.startsWith("lnurl", true)) {
|
} else if (word.startsWith("lnurl", true)) {
|
||||||
WordType.WITHDRAW
|
WordType.WITHDRAW
|
||||||
} else if (word.startsWith("cashu", true) && word.endsWith("==", true)) {
|
} else if (word.startsWith("cashuA", true)) {
|
||||||
WordType.CASHU
|
WordType.CASHU
|
||||||
} else if (Patterns.EMAIL_ADDRESS.matcher(word).matches()) {
|
} else if (Patterns.EMAIL_ADDRESS.matcher(word).matches()) {
|
||||||
WordType.EMAIL
|
WordType.EMAIL
|
||||||
|
Reference in New Issue
Block a user