Optimize price API response size reduce the number of query to that API
This commit is contained in:
@@ -327,7 +327,7 @@ export class TransactionComponent implements OnInit, AfterViewInit, OnDestroy {
|
||||
this.fetchRbfHistory$.next(this.tx.txid);
|
||||
}
|
||||
|
||||
this.priceService.getBlockPrice$(tx.status.block_time).pipe(
|
||||
this.priceService.getBlockPrice$(tx.status.block_time, true).pipe(
|
||||
tap((price) => {
|
||||
this.blockConversion = price;
|
||||
})
|
||||
|
||||
@@ -37,7 +37,7 @@ export class TxBowtieGraphTooltipComponent implements OnChanges {
|
||||
|
||||
ngOnChanges(changes): void {
|
||||
if (changes.line?.currentValue) {
|
||||
this.priceService.getBlockPrice$(changes.line?.currentValue.timestamp).pipe(
|
||||
this.priceService.getBlockPrice$(changes.line?.currentValue.timestamp, true).pipe(
|
||||
tap((price) => {
|
||||
this.blockConversion = price;
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user