mirror of
https://github.com/Fishwaldo/Foreman-Gateway.git
synced 2025-03-15 19:31:26 +00:00
Fix Crash when host has no HostGroup
This commit is contained in:
parent
ea39a84089
commit
969b4d16f5
1 changed files with 4 additions and 0 deletions
|
@ -134,6 +134,10 @@ func (fm *FM_Hosts) getHostGroupsTag(id graphql.ID) (result []string, err error)
|
|||
if v.Node.Id != id {
|
||||
continue
|
||||
}
|
||||
if v.Node.Hostgroup.ID == nil {
|
||||
logs.Info("Host Has No Hostgroup: %+v\n",v.Node)
|
||||
continue
|
||||
}
|
||||
hgid := v.Node.Hostgroup.ID.(string);
|
||||
for {
|
||||
var val string;
|
||||
|
|
Loading…
Add table
Reference in a new issue