Skip to content

Commit

Permalink
structs check TaskGroup.Update for nil
Browse files Browse the repository at this point in the history
  • Loading branch information
langmartin committed May 22, 2019
1 parent 9f74b22 commit c9a837c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion nomad/structs/structs.go
Original file line number Diff line number Diff line change
Expand Up @@ -3488,7 +3488,7 @@ func (j *Job) Warnings() error {
outer := fmt.Errorf("Group %q has warnings: %v", tg.Name, err)
mErr.Errors = append(mErr.Errors, outer)
}
if tg.Update.AutoPromote {
if tg.Update != nil && tg.Update.AutoPromote {
ap += 1
}
}
Expand Down

0 comments on commit c9a837c

Please sign in to comment.