Lily-Technologies / lily-wallet

The best way to secure your bitcoin.
https://lily-wallet.com
Other
94 stars 15 forks source link

fixes bug with tx broadcast using block explorer and testnet #35

Closed bilthon closed 4 years ago

bilthon commented 4 years ago

This PR solves two issues I found when trying to broadcast a transaction using the block explorer.

1- The block explorer's broadcast address itself seems to have been wrong. Checking at the esplora's API docs one can see there's no /broadcast endpoint. Instead a POST to /tx is what's required.

2- Bitcoin's Mainnet was always being selected no matter what the currentBitcoinNetwork variable was.

KayBeSee commented 4 years ago

Weird...when did they change the endpoint for broadcasting? I have been able to broadcast from the "old" endpoint for quite some time.