Skip to content

Commit

Permalink
fix: concurrent writes
Browse files Browse the repository at this point in the history
  • Loading branch information
tenstad committed May 12, 2022
1 parent 76b3116 commit d7d7f79
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions internal/provider/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,9 @@ func (c *apiClient) getConnWithDefault(d *schema.ResourceData) (*schema.Resource
return d, nil
}

c.mux.Lock()
defer c.mux.Unlock()

_, ok = c.resourceData.GetOk("conn")
if ok {
return c.resourceData, nil
Expand Down

0 comments on commit d7d7f79

Please sign in to comment.