From 5c4c81d288ec6d3d1c819893bdf9061a46ba8f54 Mon Sep 17 00:00:00 2001 From: lserra-iov Date: Fri, 26 Apr 2024 13:04:54 -0300 Subject: [PATCH] Add constants --- src/common/store/constants.ts | 3 +++ src/pegout/components/FlyoverPegout.vue | 2 +- src/pegout/components/PegOutForm.vue | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/common/store/constants.ts b/src/common/store/constants.ts index d2443fa9..d9169780 100644 --- a/src/common/store/constants.ts +++ b/src/common/store/constants.ts @@ -309,3 +309,6 @@ export const MAINNET_ADDRESS_NSEGWIT = '^[bc1][0-9A-HJ-NP-Za-z]{41,62}'; export const POWPEG_RSKT_HEADER = '52534b5401'; export const PEGIN_OUTPUTS = 3; export const COOKIE_EXPIRATION_HOURS = 12; + +export const POWPEG = 'powpeg'; +export const FLYOVER = 'flyover'; diff --git a/src/pegout/components/FlyoverPegout.vue b/src/pegout/components/FlyoverPegout.vue index ceca1f85..b0b2dca1 100644 --- a/src/pegout/components/FlyoverPegout.vue +++ b/src/pegout/components/FlyoverPegout.vue @@ -339,7 +339,7 @@ export default defineComponent({ })); async function send(quoteHash: string) { - const type = quoteHash ? 'flyover' : 'powpeg'; + const type = quoteHash ? constants.FLYOVER : constants.POWPEG; pegOutFormState.value.send('loading'); try { if (quoteHash) { diff --git a/src/pegout/components/PegOutForm.vue b/src/pegout/components/PegOutForm.vue index 35f9d56f..a51ec247 100644 --- a/src/pegout/components/PegOutForm.vue +++ b/src/pegout/components/PegOutForm.vue @@ -240,7 +240,7 @@ export default defineComponent({ name: 'PegOutSuccess', params: { wallet: currentWallet.value, - type: 'powpeg', + type: constants.POWPEG, }, }); context.emit('changePage', nextPage);