Skip to content

Commit 9b97aee

Browse files
authored
fix(group/project): Fixes invitation query (#2206)
Signed-off-by: Javier Rodriguez <[email protected]>
1 parent f0624ac commit 9b97aee

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

app/controlplane/pkg/data/group.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,8 +172,8 @@ func (g GroupRepo) ListPendingInvitationsByGroup(ctx context.Context, orgID uuid
172172
orginvitation.OrganizationIDEQ(orgID),
173173
orginvitation.DeletedAtIsNil(),
174174
orginvitation.StatusEQ(biz.OrgInvitationStatusPending),
175-
func(_ *sql.Selector) {
176-
sqljson.ValueEQ(orginvitation.FieldContext, groupID.String(), sqljson.DotPath("group_id_to_join"))
175+
func(s *sql.Selector) {
176+
s.Where(sqljson.ValueEQ(orginvitation.FieldContext, groupID.String(), sqljson.DotPath("group_id_to_join")))
177177
},
178178
).
179179
WithOrganization().

app/controlplane/pkg/data/project.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -388,8 +388,8 @@ func (r *ProjectRepo) ListPendingInvitationsByProject(ctx context.Context, orgID
388388
orginvitation.OrganizationIDEQ(orgID),
389389
orginvitation.DeletedAtIsNil(),
390390
orginvitation.StatusEQ(biz.OrgInvitationStatusPending),
391-
func(_ *sql.Selector) {
392-
sqljson.ValueEQ(orginvitation.FieldContext, projectID.String(), sqljson.DotPath("project_id_to_join"))
391+
func(s *sql.Selector) {
392+
s.Where(sqljson.ValueEQ(orginvitation.FieldContext, projectID.String(), sqljson.DotPath("project_id_to_join")))
393393
},
394394
).
395395
WithOrganization().

0 commit comments

Comments
 (0)