This commit is contained in:
@@ -73,7 +73,7 @@ func (h *Handler) VmModifyEvent(w http.ResponseWriter, r *http.Request) {
|
||||
w.WriteHeader(http.StatusAccepted)
|
||||
json.NewEncoder(w).Encode(map[string]string{
|
||||
"status": "OK",
|
||||
"message": fmt.Sprintf("Received update event successfully but no config changes were found"),
|
||||
"message": "Received update event successfully but no config changes were found",
|
||||
})
|
||||
return
|
||||
} else {
|
||||
@@ -178,7 +178,7 @@ func (h *Handler) VmModifyEvent(w http.ResponseWriter, r *http.Request) {
|
||||
} else {
|
||||
h.Logger.Debug("Matched regex", "disk_owner", matches[1])
|
||||
|
||||
if strings.ToLower(matches[1]) == strings.ToLower(event.CloudEvent.Data.VM.Name) {
|
||||
if strings.EqualFold(matches[1], event.CloudEvent.Data.VM.Name) {
|
||||
h.Logger.Debug("This disk belongs to this VM")
|
||||
changeFound = true
|
||||
diskChangeFound = true
|
||||
@@ -278,7 +278,7 @@ func (h *Handler) VmModifyEvent(w http.ResponseWriter, r *http.Request) {
|
||||
w.WriteHeader(http.StatusOK)
|
||||
json.NewEncoder(w).Encode(map[string]string{
|
||||
"status": "OK",
|
||||
"message": fmt.Sprintf("Successfully processed vm modify event"),
|
||||
"message": "Successfully processed vm modify event",
|
||||
})
|
||||
return
|
||||
}
|
||||
@@ -304,7 +304,7 @@ func (h *Handler) VmModifyEvent(w http.ResponseWriter, r *http.Request) {
|
||||
w.WriteHeader(http.StatusOK)
|
||||
json.NewEncoder(w).Encode(map[string]string{
|
||||
"status": "OK",
|
||||
"message": fmt.Sprintf("Successfully processed vm modify event"),
|
||||
"message": "Successfully processed vm modify event",
|
||||
})
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user