diff --git a/gateway.go b/gateway.go index d938ece..abbee1c 100644 --- a/gateway.go +++ b/gateway.go @@ -210,10 +210,10 @@ func (ws *socketConn) handleStatus(updates Packet) { var table = "" for statusCode, value := range msg.Updates { - if strings.Contains(statusCode, "status.") { + if strings.Contains(statusCode, "fault.") { // We have a status update table = "generator_faults" - } else if strings.Contains(statusCode, "fault.") { + } else if strings.Contains(statusCode, "status.") { // We have fault update table = "generator_statuses" }