diff --git a/api/policy_exceptions.go b/api/policy_exceptions.go index 23b1228c0..e6b648e3b 100644 --- a/api/policy_exceptions.go +++ b/api/policy_exceptions.go @@ -104,6 +104,6 @@ type PolicyException struct { } type PolicyExceptionConstraint struct { - FieldKey string `json:"fieldKey"` - FieldValues []string `json:"fieldValues"` + FieldKey string `json:"fieldKey"` + FieldValues []any `json:"fieldValues"` } diff --git a/api/policy_exceptions_test.go b/api/policy_exceptions_test.go index ca1a8a5fd..5c77d03e1 100644 --- a/api/policy_exceptions_test.go +++ b/api/policy_exceptions_test.go @@ -237,7 +237,7 @@ func TestPolicyExceptionUpdate(t *testing.T) { policyException := api.PolicyException{ Description: "exception description", - Constraints: []api.PolicyExceptionConstraint{{FieldKey: "accountIds", FieldValues: []string{"*"}}}, + Constraints: []api.PolicyExceptionConstraint{{FieldKey: "accountIds", FieldValues: []any{"*"}}}, } assert.Equal(t, "exception description", policyException.Description, "policy exception description mismatch") assert.Equal(t, "accountIds", policyException.Constraints[0].FieldKey, "policy exception field key mismatch")