Skip to content

Commit

Permalink
Remove panic
Browse files Browse the repository at this point in the history
  • Loading branch information
marcobebway committed Jan 11, 2024
1 parent a4bceab commit d952f64
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion testing/eventmeshmock.go
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,9 @@ func (m *EventMeshMock) handleMessaging() func(w http.ResponseWriter, r *http.Re
if i < two { // Don't sleep after the last attempt
time.Sleep(time.Duration(three) * time.Second)
} else {
panic(err)
m.log.Error(err, "failed to update state response")
w.WriteHeader(http.StatusBadRequest)
return
}
}
case http.MethodGet:
Expand Down

0 comments on commit d952f64

Please sign in to comment.