From b2ca749ff371d88a9964e75265a5a95b1d5be2da Mon Sep 17 00:00:00 2001 From: Vlad Stan Date: Tue, 11 Oct 2022 15:55:18 +0300 Subject: [PATCH] refactor: re-order methods --- .../extensions/cashu/templates/cashu/wallet.html | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/lnbits/extensions/cashu/templates/cashu/wallet.html b/lnbits/extensions/cashu/templates/cashu/wallet.html index 385143e1..641b704c 100644 --- a/lnbits/extensions/cashu/templates/cashu/wallet.html +++ b/lnbits/extensions/cashu/templates/cashu/wallet.html @@ -931,6 +931,14 @@ page_container %} } }, + requestTokens: async function (amounts, paymentHash) { + const newTokens = await this.buildTokens(amounts, paymentHash) + this.tokens.push(newTokens) + this.storeTokens() + console.log('### this.tokens', this.tokens) + await this.fetchPromisesFromMint(paymentHash, newTokens.newTokens) + }, + fetchPromisesFromMint: async function (hash, blindedMessages) { console.log('### fetchPromisesFromMint', hash, blindedMessages) try { @@ -950,14 +958,6 @@ page_container %} } }, - requestTokens: async function (amounts, paymentHash) { - const newTokens = await this.buildTokens(amounts, paymentHash) - this.tokens.push(newTokens) - this.storeTokens() - console.log('### this.tokens', this.tokens) - await this.fetchPromisesFromMint(paymentHash, newTokens.newTokens) - }, - buildAnsShowTokens: async function () { this.sendData.tokens = 'toookeeens:' + this.sendData.amount },