Migrate to new self-hosted mempool.space instance (#1820)

Co-authored-by: Omar Hatem <omarh.ismail1@gmail.com>
This commit is contained in:
Seth For Privacy
2024-11-26 16:56:00 +02:00
committed by GitHub
co-authored by Omar Hatem
parent 738731d3e5
commit eff6616981
3 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -1707,7 +1707,7 @@ abstract class ElectrumWalletBase
try {
final blockHash = await http.get(
Uri.parse(
"http://mempool.cakewallet.com:8999/api/v1/block-height/$height",
"https://mempool.cakewallet.com/api/v1/block-height/$height",
),
);
@@ -1716,7 +1716,7 @@ abstract class ElectrumWalletBase
jsonDecode(blockHash.body) != null) {
final blockResponse = await http.get(
Uri.parse(
"http://mempool.cakewallet.com:8999/api/v1/block/${blockHash.body}",
"https://mempool.cakewallet.com/api/v1/block/${blockHash.body}",
),
);
if (blockResponse.statusCode == 200 &&
+1 -1
View File
@@ -270,7 +270,7 @@ const bitcoinDates = {
Future<int> getBitcoinHeightByDateAPI({required DateTime date}) async {
final response = await http.get(
Uri.parse(
"http://mempool.cakewallet.com:8999/api/v1/mining/blocks/timestamp/${(date.millisecondsSinceEpoch / 1000).round()}",
"https://mempool.cakewallet.com/api/v1/mining/blocks/timestamp/${(date.millisecondsSinceEpoch / 1000).round()}",
),
);
@@ -159,7 +159,7 @@ abstract class TransactionDetailsViewModelBase with Store {
case WalletType.monero:
return 'https://monero.com/tx/${txId}';
case WalletType.bitcoin:
return 'https://mempool.space/${wallet.isTestnet ? "testnet/" : ""}tx/${txId}';
return 'https://mempool.cakewallet.com/${wallet.isTestnet ? "testnet/" : ""}tx/${txId}';
case WalletType.litecoin:
return 'https://blockchair.com/litecoin/transaction/${txId}';
case WalletType.bitcoinCash: