Merge pull request #4787 from mempool/natsoni/fix-load-more-p2pk

Fix broken load more for P2PK address page
This commit is contained in:
softsimon 2024-03-18 15:27:39 +09:00 committed by GitHub
commit 634b461bb5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -253,7 +253,9 @@ export class AddressComponent implements OnInit, OnDestroy {
}
this.isLoadingTransactions = true;
this.retryLoadMore = false;
this.electrsApiService.getAddressTransactions$(this.address.address, this.lastTransactionTxId)
(this.address.is_pubkey
? this.electrsApiService.getScriptHashTransactions$((this.address.address.length === 66 ? '21' : '41') + this.address.address + 'ac', this.lastTransactionTxId)
: this.electrsApiService.getAddressTransactions$(this.address.address, this.lastTransactionTxId))
.subscribe((transactions: Transaction[]) => {
if (transactions && transactions.length) {
this.lastTransactionTxId = transactions[transactions.length - 1].txid;