mirror of
https://github.com/fleetdm/fleet
synced 2026-05-22 08:28:52 +00:00
Handle undefined host.software in device user UI (#19415)
This commit is contained in:
parent
893766efdd
commit
68c805dfe2
2 changed files with 2 additions and 2 deletions
|
|
@ -301,7 +301,7 @@ export interface IHost {
|
|||
gigs_disk_space_available: number;
|
||||
labels: ILabel[];
|
||||
packs: IPack[];
|
||||
software: ISoftware[];
|
||||
software?: ISoftware[];
|
||||
issues: IHostIssues;
|
||||
status: HostStatus;
|
||||
display_text: string;
|
||||
|
|
|
|||
|
|
@ -339,7 +339,7 @@ const DeviceUserPage = ({
|
|||
// Software in the legacy response is only being used as a proxy for `iseSoftwareEnabled`.
|
||||
// Ideally we should be checking the config for whether software is enabled to show/hide the tab,
|
||||
// but it isn't available via device token authenticated API. And we need better specified empty states.
|
||||
const isSoftwareEnabled = !!host?.software.length;
|
||||
const isSoftwareEnabled = !!host?.software?.length;
|
||||
|
||||
return (
|
||||
<div className="core-wrapper">
|
||||
|
|
|
|||
Loading…
Reference in a new issue