Skip to content

Commit

Permalink
tailscale: update state after modification for ACL resource (#364)
Browse files Browse the repository at this point in the history
Adds calls to `Read` after doing `Create` or `Update` operations for the
ACL resource. This resource was missed in #362 where it was added for
other existing resources.

Fixes tailscale/corp#19698

Signed-off-by: Mario Minardi <mario@tailscale.com>
  • Loading branch information
mpminardi committed May 6, 2024
1 parent ae7d025 commit 5088fb1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tailscale/resource_acl.go
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ func resourceACLCreate(ctx context.Context, d *schema.ResourceData, m interface{
}

d.SetId(createUUID())
return nil
return resourceACLRead(ctx, d, m)
}

func resourceACLUpdate(ctx context.Context, d *schema.ResourceData, m interface{}) diag.Diagnostics {
Expand All @@ -146,5 +146,5 @@ func resourceACLUpdate(ctx context.Context, d *schema.ResourceData, m interface{
return diagnosticsError(err, "Failed to set ACL")
}

return nil
return resourceACLRead(ctx, d, m)
}

0 comments on commit 5088fb1

Please sign in to comment.