@sats-connect/core
Advanced tools
Comparing version 0.0.1-f5ee597 to 0.0.2-2bfa1ee
@@ -37,5 +37,6 @@ "use strict"; | ||
const addressType = (0, bitcoin_address_validation_1.getAddressInfo)(accounts[0]).type; | ||
const pk = addressType === bitcoin_address_validation_1.AddressType.p2tr ? publicKey.slice(2) : publicKey; | ||
const paymentAddress = { | ||
address, | ||
publicKey, | ||
publicKey: pk, | ||
addressType, | ||
@@ -46,3 +47,3 @@ purpose: addresses_1.AddressPurpose.Payment, | ||
address, | ||
publicKey, | ||
publicKey: pk, | ||
addressType, | ||
@@ -81,5 +82,8 @@ purpose: addresses_1.AddressPurpose.Ordinals, | ||
const { recipients } = params; | ||
const response = await Promise.all(recipients.map((recipient) => window.unisat.sendBitcoin(recipient.address, recipient.amount))); | ||
if (recipients.length > 1) { | ||
throw new Error('Only one recipient is supported by this wallet provider'); | ||
} | ||
const txid = await window.unisat.sendBitcoin(recipients[0].address, recipients[0].amount); | ||
return { | ||
txid: response[0], | ||
txid, | ||
}; | ||
@@ -86,0 +90,0 @@ } |
{ | ||
"name": "@sats-connect/core", | ||
"version": "0.0.1-f5ee597", | ||
"version": "0.0.2-2bfa1ee", | ||
"main": "dist/index.js", | ||
@@ -5,0 +5,0 @@ "files": [ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
123668
1583