Skip to content

Commit d43d147

Browse files
committed
safer validation to prevent SQL injection attacks.
Signed-off-by: aryan <aryan1bhokare@gmail.com>
1 parent e4d9ab7 commit d43d147

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

chaoscenter/authentication/pkg/project/repository.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ func (r repository) GetOwnerProjects(ctx context.Context, userID string) ([]*ent
384384

385385
// GetProjectOwners takes projectID and returns the owners
386386
func (r repository) GetProjectOwners(projectID string) ([]*entities.Member, error) {
387-
filter := bson.D{{"_id", projectID}}
387+
filter := bson.M{{"_id", projectID}}
388388

389389
var project struct {
390390
Members []*entities.Member `bson:"members"`

0 commit comments

Comments
 (0)