Skip to content

Commit

Permalink
fix nil check for query_string
Browse files Browse the repository at this point in the history
  • Loading branch information
jacobbednarz committed Mar 3, 2021
1 parent 0cadda6 commit ab7b841
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cloudflare/resource_cloudflare_page_rule.go
Original file line number Diff line number Diff line change
Expand Up @@ -899,7 +899,7 @@ func transformToCloudflarePageRuleAction(id string, value interface{}, d *schema
// Ensure that if no `include`, `exclude` or `ignore` attributes are
// set, we default to including all query string parameters in the
// cache key.
if !ignore.(bool) {
if ignore == nil || !ignore.(bool) {
if (!ok1 || len(exclude.([]interface{})) == 0) && (!ok2 || len(include.([]interface{})) == 0) {
sectionOutput["include"] = "*"
}
Expand Down

0 comments on commit ab7b841

Please sign in to comment.