Typo fix
parent
474f8fb098
commit
35c7bbb5b4
4
main.go
4
main.go
|
@ -280,12 +280,12 @@ func statusHandler(config Config, w http.ResponseWriter, r *http.Request) {
|
||||||
for key, value := range result {
|
for key, value := range result {
|
||||||
if strings.HasSuffix(key, "_state") {
|
if strings.HasSuffix(key, "_state") {
|
||||||
// If there is "*_state": "error" - it's accessible, but unavailable
|
// If there is "*_state": "error" - it's accessible, but unavailable
|
||||||
if valueStr, ok := value(string); ok && valueStr == "error" {
|
if valueStr, ok := value.(string); ok && valueStr == "error" {
|
||||||
available = false
|
available = false
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
// If there is "*_state": "running" - it's OK
|
// If there is "*_state": "running" - it's OK
|
||||||
if valueStr, ok := value(string); ok && valueStr == "running" {
|
if valueStr, ok := value.(string); ok && valueStr == "running" {
|
||||||
available = true
|
available = true
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue