Skip to content

Commit

Permalink
resource pullzone_optimizer_class: some fields were wrongly escaped
Browse files Browse the repository at this point in the history
  • Loading branch information
rafael-at-bunny committed Sep 9, 2024
1 parent ea4397a commit 90ba83d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
> [!NOTE]
> While we strive to maintain backwards compatibility as much as possible, we can't guarantee semantic versioning will be strictly followed, as this provider depends on the underlying [bunny.net API](https://docs.bunny.net/reference/bunnynet-api-overview).
## [0.3.13] - 2024-09-09
### Fixed
- resource pullzone_optimizer_class: some fields were wrongly escaped ([#11](https://github.com/BunnyWay/terraform-provider-bunnynet/issues/11))

## [0.3.12] - 2024-09-06
## Added
- data source bunnynet_dns_zone
Expand Down
8 changes: 4 additions & 4 deletions internal/provider/resource_pullzone_optimizer_class.go
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ func (r *PullzoneOptimizerClassResource) convertModelToApi(ctx context.Context,
}

if !dataTf.AspectRatio.IsNull() {
properties["aspect_ratio"] = dataTf.AspectRatio.String()
properties["aspect_ratio"] = dataTf.AspectRatio.ValueString()
}

if !dataTf.Quality.IsNull() {
Expand All @@ -401,11 +401,11 @@ func (r *PullzoneOptimizerClassResource) convertModelToApi(ctx context.Context,
}

if !dataTf.Crop.IsNull() {
properties["crop"] = dataTf.Crop.String()
properties["crop"] = dataTf.Crop.ValueString()
}

if !dataTf.CropGravity.IsNull() {
properties["crop_gravity"] = dataTf.CropGravity.String()
properties["crop_gravity"] = dataTf.CropGravity.ValueString()
}

if !dataTf.Flip.IsNull() {
Expand Down Expand Up @@ -443,7 +443,7 @@ func (r *PullzoneOptimizerClassResource) convertModelToApi(ctx context.Context,
}

if !dataTf.AutoOptimize.IsNull() {
properties["auto_optimize"] = dataTf.AutoOptimize.String()
properties["auto_optimize"] = dataTf.AutoOptimize.ValueString()
}

if !dataTf.Sepia.IsNull() {
Expand Down

0 comments on commit 90ba83d

Please sign in to comment.