Skip to content

Commit

Permalink
fix: create idp in postgres
Browse files Browse the repository at this point in the history
  • Loading branch information
boojack committed May 29, 2024
1 parent f2b708c commit 423861d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion store/db/postgres/idp.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (

func (d *DB) CreateIdentityProvider(ctx context.Context, create *store.IdentityProvider) (*store.IdentityProvider, error) {
fields := []string{"name", "type", "identifier_filter", "config"}
args := []any{create.Name, create.Type.Type(), create.IdentifierFilter, create.Config}
args := []any{create.Name, create.Type.String(), create.IdentifierFilter, create.Config}
stmt := "INSERT INTO idp (" + strings.Join(fields, ", ") + ") VALUES (" + placeholders(len(args)) + ") RETURNING id"
if err := d.db.QueryRowContext(ctx, stmt, args...).Scan(&create.ID); err != nil {
return nil, err
Expand Down

0 comments on commit 423861d

Please sign in to comment.