Skip to content

Commit

Permalink
fix(executors): handle nil response (#505)
Browse files Browse the repository at this point in the history
  • Loading branch information
JordanSussman authored Oct 21, 2021
1 parent 8ac08a6 commit 928a4d4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion router/middleware/executors/executors.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ func Establish() gin.HandlerFunc {

// make the request to the worker and check the response
resp, err := client.Do(req)
if err != nil {
if err != nil || resp == nil {
// abandoned builds might have ran on a worker that no longer exists
// if the worker is unavailable write an empty slice ToContext
ToContext(c, *e)
Expand Down

0 comments on commit 928a4d4

Please sign in to comment.