bugfix: available_services types and getter in topbar

Signed-off-by: Stefan Dej <meteyou@gmail.com>
This commit is contained in:
Stefan Dej
2021-08-24 22:47:16 +02:00
parent aed9caef6b
commit c346510cdf
2 changed files with 2 additions and 2 deletions

View File

@@ -59,7 +59,7 @@ export default class TheTopCornerMenu extends Mixins(BaseMixin) {
showMenu = false
get services() {
const services = this.$store.state.server.system_info.available_services?.filter((name: string) => name !== 'klipper_mcu') ?? []
const services = this.$store.state.server.system_info?.available_services?.filter((name: string) => name !== 'klipper_mcu') ?? []
services.sort()
return services
}

View File

@@ -16,7 +16,7 @@ export interface ServerState {
[key: string]: any
},
system_info: {
available_services: { [key: number]: string }[]
available_services: string[]
cpu_info: ServerStateCpuInfo
distribution: ServerStateDistribution
sd_info: ServerStateSdInfo