Fix rendering issue when clicking on block link from pool page

This commit is contained in:
nymkappa committed 2022-02-15 18:36:58 +09:00
1 parent ef529f3da0
commit 5ff4de4059
3 files changed
+10 -14

No files matched your search

+4 -7
View File
@@ -138,12 +138,9 @@ export class ApiService {
}
getPoolBlocks$(poolId: number, fromHeight: number): Observable<BlockExtended[]> {
if (fromHeight !== undefined) {
return this.httpClient.get<BlockExtended[]>(this.apiBaseUrl + this.apiBasePath +
`/api/v1/mining/pool/${poolId}/blocks/${fromHeight}`);
} else {
return this.httpClient.get<BlockExtended[]>(this.apiBaseUrl + this.apiBasePath +
`/api/v1/mining/pool/${poolId}/blocks`);
}
return this.httpClient.get<BlockExtended[]>(
this.apiBaseUrl + this.apiBasePath + `/api/v1/mining/pool/${poolId}/blocks` +
(fromHeight !== undefined ? `/${fromHeight}` : '')
);
}
}