bump branta version

This commit is contained in:
Blake Kaufman
2026-05-19 12:18:17 -04:00
parent 0cadeca6b0
commit 56a9f00644
5 changed files with 23 additions and 16 deletions
@@ -256,8 +256,8 @@ export default async function decodeSendAddress(props) {
if (shouldRunBrantaVerification) {
brantaVerificationPromise.then(brantaResult => {
if (brantaResult && brantaResult.length) {
const [details] = brantaResult;
if (brantaResult && brantaResult.payments?.length) {
const [details] = brantaResult.payments;
if (details.platformLogoUrl) {
ExpoImage.prefetch(details.platformLogoUrl).catch(err =>
console.log('Error prefetching branta merchant logo', err),
@@ -314,8 +314,8 @@ export default async function decodeSendAddress(props) {
};
}
if (brantaVerification && brantaVerification.length) {
const [details] = brantaVerification;
if (brantaVerification && brantaVerification.payments?.length) {
const [details] = brantaVerification.payments;
const isHttpsUrl = val =>
typeof val === 'string' && val.startsWith('https://');
processedPaymentInfo = {
@@ -325,8 +325,8 @@ export default async function decodeSendAddress(props) {
brantaMerchantLogo: isHttpsUrl(details.platformLogoUrl)
? details.platformLogoUrl
: undefined,
verificationURL: isHttpsUrl(details.verifyUrl)
? details.verifyUrl
verificationURL: isHttpsUrl(brantaVerification.verifyUrl)
? brantaVerification.verifyUrl
: undefined,
};
}
+5 -3
View File
@@ -1,13 +1,15 @@
import { BrantaServerBaseUrl, V2BrantaClient } from '@branta-ops/branta';
import { BrantaServerBaseUrl } from '@branta-ops/branta';
import { BrantaService } from '@branta-ops/branta/v2';
const brantaClient = new V2BrantaClient({
const service = new BrantaService({
baseUrl: BrantaServerBaseUrl.Production,
privacy: 'strict',
});
export async function handleBrantaVerification(qrCode) {
try {
const brantaResponse = await brantaClient.getPaymentsByQRCode(qrCode ?? '');
const brantaResponse = await service.getPaymentsByQrCode(qrCode ?? '');
console.log(brantaResponse);
return brantaResponse;
} catch (err) {
console.log('Error retriving branta verification', err);
+2 -1
View File
@@ -18,7 +18,7 @@
},
"dependencies": {
"@azure/core-asynciterator-polyfill": "^1.0.2",
"@branta-ops/branta": "2.0.0",
"@branta-ops/branta": "^3.1.2",
"@breeztech/react-native-breez-sdk-liquid": "^0.11.9",
"@buildonspark/spark-sdk": "^0.8.0",
"@craftzdog/react-native-buffer": "^6.1.0",
@@ -103,6 +103,7 @@
"react-native-safe-area-context": "~5.6.0",
"react-native-screens": "~4.16.0",
"react-native-svg": "15.12.1",
"react-native-url-polyfill": "^3.0.0",
"react-native-view-shot": "^4.0.3",
"react-native-vision-camera": "^5.0.9",
"react-native-vision-camera-barcode-scanner": "^5.0.9",
+3
View File
@@ -6,6 +6,9 @@ import '@azure/core-asynciterator-polyfill';
//neeed for encription + spark
import 'react-native-quick-base64';
// needed for branta ops
import 'react-native-url-polyfill/auto';
import { Buffer } from '@craftzdog/react-native-buffer';
import QuickCrypto, {
pbkdf2Sync,
+7 -6
View File
@@ -1776,10 +1776,10 @@ __metadata:
languageName: node
linkType: hard
"@branta-ops/branta@npm:2.0.0":
version: 2.0.0
resolution: "@branta-ops/branta@npm:2.0.0"
checksum: 6966c87c85ee8547541849aa5b5499c8927b5808f79ab4f96f3ad38c0ff21f1162f381c1f4c196adf4ee6b9378e09463e0c2fe81a03d4c58f724ae4a0adce4e0
"@branta-ops/branta@npm:^3.1.2":
version: 3.1.2
resolution: "@branta-ops/branta@npm:3.1.2"
checksum: f9e5947ad8e812e296c4a5bf41da1919101bdd3dc5501095f74605d398b30c6b4528f35dfebf4b9480b3ed36edcdad0e701df415d4c712c640d8e4f507bf77a2
languageName: node
linkType: hard
@@ -4919,7 +4919,7 @@ __metadata:
"@babel/plugin-transform-class-static-block": ^7.28.3
"@babel/preset-env": ^7.28.3
"@babel/runtime": ^7.25.0
"@branta-ops/branta": 2.0.0
"@branta-ops/branta": ^3.1.2
"@breeztech/react-native-breez-sdk-liquid": ^0.11.9
"@buildonspark/spark-sdk": ^0.8.0
"@craftzdog/react-native-buffer": ^6.1.0
@@ -5022,6 +5022,7 @@ __metadata:
react-native-safe-area-context: ~5.6.0
react-native-screens: ~4.16.0
react-native-svg: 15.12.1
react-native-url-polyfill: ^3.0.0
react-native-view-shot: ^4.0.3
react-native-vision-camera: ^5.0.9
react-native-vision-camera-barcode-scanner: ^5.0.9
@@ -13329,7 +13330,7 @@ __metadata:
languageName: node
linkType: hard
"react-native-url-polyfill@npm:3.0.0":
"react-native-url-polyfill@npm:3.0.0, react-native-url-polyfill@npm:^3.0.0":
version: 3.0.0
resolution: "react-native-url-polyfill@npm:3.0.0"
dependencies: