mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-26 10:21:52 +00:00
just set this.metrics
This commit is contained in:
committed by
Aiden McClelland
parent
25775ab2a1
commit
4d86d13e48
@@ -54,15 +54,7 @@ export class ServerMetricsPage {
|
||||
|
||||
private async getMetrics (): Promise<void> {
|
||||
try {
|
||||
const metrics = await this.embassyApi.getServerMetrics({ })
|
||||
Object.entries(metrics).forEach(([groupKey, groupVal]) => {
|
||||
if (!this.metrics[groupKey]) {
|
||||
this.metrics[groupKey] = groupVal
|
||||
}
|
||||
Object.entries(groupVal).forEach(([key, val]) => {
|
||||
this.metrics[groupKey][key] = val
|
||||
})
|
||||
})
|
||||
this.metrics = await this.embassyApi.getServerMetrics({ })
|
||||
} catch (e) {
|
||||
this.errToast.present(e)
|
||||
this.stopDaemon()
|
||||
|
||||
Reference in New Issue
Block a user