mirror of
https://github.com/opentofu/opentofu.git
synced 2025-02-20 11:48:24 -06:00
Simplify setting up EscalationPolicy
This commit is contained in:
parent
69fb733ad0
commit
35312f0066
@ -61,9 +61,13 @@ func buildServiceStruct(d *schema.ResourceData) *pagerduty.Service {
|
||||
service.AcknowledgementTimeout = &acknowledgementTimeout
|
||||
}
|
||||
|
||||
policy := &pagerduty.EscalationPolicy{}
|
||||
policy.ID = d.Get("escalation_policy").(string)
|
||||
policy.Type = "escalation_policy"
|
||||
policy := &pagerduty.EscalationPolicy{
|
||||
APIObject: pagerduty.APIObject{
|
||||
ID: d.Get("escalation_policy").(string),
|
||||
Type: "escalation_policy",
|
||||
},
|
||||
}
|
||||
|
||||
service.EscalationPolicy = *policy
|
||||
|
||||
return &service
|
||||
|
Loading…
Reference in New Issue
Block a user