From 23188d38ba14192f1323fc6e7854af207ff09df3 Mon Sep 17 00:00:00 2001 From: 22388o <22388o@users.noreply.github.com> Date: Fri, 20 Dec 2024 15:26:57 -0300 Subject: [PATCH] Fix payjoin --- src/app/payjoin/index.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/app/payjoin/index.ts b/src/app/payjoin/index.ts index a496b7d..ccdb1c2 100644 --- a/src/app/payjoin/index.ts +++ b/src/app/payjoin/index.ts @@ -1,5 +1,6 @@ // Import PayjoinURL from the 'payjoin-react-native' package -import { PayjoinURL, UTXO } from 'payjoin-react-native'; +import { PayjoinURL } from 'payjoin-react-native'; +import { UTXO } from 'silent-payments'; export const PayJoin = (url: string) => { // Create a PayjoinURL instance @@ -14,7 +15,7 @@ export const sendPSBT = async (psbt: string) => { // Send the PSBT to the payjoin server const response = await fetch('https://payjoin.example.com/payjoin', { method: 'POST', - headers + Headers }); return response; }// Reaceive the response from the payjoin server @@ -29,5 +30,8 @@ const utxo: UTXO = { value: 1000000, script: 'scriptPubKey', } + +// Use the utxo variable +console.log(utxo) return response;// Export PayJoin and PayjoinURL export { PayjoinURL };