Skip to content

Commit

Permalink
Required weekday fix (#15)
Browse files Browse the repository at this point in the history
* fixing golang syntax errors in resource_build_trigger_schedule
  • Loading branch information
rjh-yext authored Dec 6, 2022
1 parent e8756c8 commit 13ffc9a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions teamcity/resource_build_trigger_schedule.go
Original file line number Diff line number Diff line change
Expand Up @@ -215,8 +215,7 @@ func resourceBuildTriggerScheduleCreate(d *schema.ResourceData, meta interface{}
}

if strings.EqualFold(schedule, "weekly") {
triggerWeekday, ok := d.GetOk("weekday")
if !ok {
if _, ok := d.GetOk("weekday"); !ok {
return fmt.Errorf("weekday is required if a schedule of weekly is chosen")
}
}
Expand Down

0 comments on commit 13ffc9a

Please sign in to comment.