better host upstream support

This commit is contained in:
Jamie Curnow
2023-01-09 13:18:11 +10:00
parent 0a50672ab6
commit ca4d92d793
6 changed files with 30 additions and 7 deletions

View File

@ -87,6 +87,11 @@ func CreateHost() func(http.ResponseWriter, *http.Request) {
return
}
if newHost.UpstreamID > 0 {
// nolint: errcheck, gosec
newHost.Expand([]string{"upstream"})
}
configureHost(newHost)
h.ResultResponseJSON(w, r, http.StatusOK, newHost)