[accelerator] fix accel status in widget

This commit is contained in:
nymkappa 2024-08-02 00:20:34 +02:00
parent c5beee3a40
commit 3f2581886d
No known key found for this signature in database
GPG Key ID: 92358FC85D9645DE

View File

@ -50,6 +50,12 @@ export class AccelerationsListComponent implements OnInit, OnDestroy {
}
ngOnInit(): void {
this.miningService.getPools().subscribe(pools => {
for (const pool of pools) {
this.pools[pool.unique_id] = pool;
}
});
if (!this.widget) {
this.websocketService.want(['blocks']);
this.seoService.setTitle($localize`:@@02573b6980a2d611b4361a2595a4447e390058cd:Accelerations`);
@ -82,12 +88,6 @@ export class AccelerationsListComponent implements OnInit, OnDestroy {
).subscribe(() => {
this.pageChange(this.page);
});
this.miningService.getPools().subscribe(pools => {
for (const pool of pools) {
this.pools[pool.unique_id] = pool;
}
});
}
this.skeletonLines = this.widget === true ? [...Array(6).keys()] : [...Array(15).keys()];