Skip to content

Commit

Permalink
Fix clear_on_destroy state
Browse files Browse the repository at this point in the history
Signed-off-by: Andy Lo-A-Foe <[email protected]>
  • Loading branch information
loafoe committed Mar 12, 2021
1 parent 5922811 commit 3cf2dba
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@ All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).
## v0.13.2
- Fix clear_on_destroy state

## v0.13.1
- Documentation fix

## v0.13.0
- Support `ensure_tcp` and `ensure_udp` in STL firewall exception config
- Documentation fixes
Expand Down
3 changes: 2 additions & 1 deletion hsdp/resource_stl_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -330,6 +330,7 @@ func dataToResourceData(fwExceptions *stl.AppFirewallException, appLogging *stl.
if !hasFirewallExceptionField(d, "ensure_udp") {
fwExceptionsDef["udp"] = fwExceptions.UDP
}
fwExceptionsDef["clear_on_destroy"] = clearFirewallExceptionsOnDestroy(d)
s.Add(fwExceptionsDef)
_, _ = config.Debug("Adding firewall exceptions data\n")
err := d.Set("firewall_exceptions", s)
Expand Down Expand Up @@ -418,7 +419,7 @@ func clearFirewallExceptionsOnDestroy(d *schema.ResourceData) bool {
}
}
}
return false
return true
}

func hasFirewallExceptionField(d *schema.ResourceData, fieldName string) bool {
Expand Down

0 comments on commit 3cf2dba

Please sign in to comment.