Skip to content

Commit

Permalink
fix group data source
Browse files Browse the repository at this point in the history
  • Loading branch information
maciaszczykm committed Jul 25, 2024
1 parent f46a276 commit 584fce6
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 1 deletion.
20 changes: 20 additions & 0 deletions example/user/main.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
terraform {
required_providers {
plural = {
source = "pluralsh/plural"
version = "0.2.1"
}
}
}

provider "plural" {
use_cli = true
}

data "plural_user" "user" {
email = "[email protected]"
}

data "plural_group" "group" {
name = "team"
}
2 changes: 1 addition & 1 deletion internal/model/group.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ type Group struct {
func (g *Group) From(response *gqlclient.GroupFragment) {
g.Id = types.StringValue(response.ID)
g.Name = types.StringValue(response.Name)
g.Name = types.StringPointerValue(response.Description)
g.Description = types.StringPointerValue(response.Description)
}

func (g *Group) Attributes() gqlclient.GroupAttributes {
Expand Down

0 comments on commit 584fce6

Please sign in to comment.