MCPcopy Create free account
hub / github.com/PatchMon/PatchMon / hostDisplayName

Function hostDisplayName

server-source-code/internal/alerts/host_down.go:277–285  ·  view source on GitHub ↗
(host db.Host)

Source from the content-addressed store, hash-verified

275}
276
277func hostDisplayName(host db.Host) string {
278 if host.FriendlyName != "" {
279 return host.FriendlyName
280 }
281 if host.Hostname != nil && *host.Hostname != "" {
282 return *host.Hostname
283 }
284 return host.ApiID
285}
286
287func hostDisplayNameFromRow(host db.Host) string {
288 return hostDisplayName(host)

Callers 3

ProcessHostStatusMonitorFunction · 0.85
hostDisplayNameFromRowFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected