mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-12 11:47:34 +00:00
fix repo
This commit is contained in:
@@ -78,12 +78,7 @@ func (cmd *CreateOrganizationCommand) Execute(ctx context.Context, opts *Command
|
||||
}
|
||||
defer func() { err = close(ctx, err) }()
|
||||
|
||||
err = orgRepo(opts.DB).Create(ctx, &Organization{
|
||||
ID: cmd.ID,
|
||||
Name: cmd.Name,
|
||||
InstanceID: cmd.InstanceID,
|
||||
State: OrgStateActive,
|
||||
})
|
||||
err = orgRepo(opts.DB).Create(ctx, cmd)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
@@ -15,7 +15,7 @@ type OrganizationRepository interface {
|
||||
Get(ctx context.Context, opts ...database.QueryOption) (*Organization, error)
|
||||
List(ctx context.Context, opts ...database.QueryOption) ([]*Organization, error)
|
||||
|
||||
Create(ctx context.Context, instance *Organization) error
|
||||
Create(ctx context.Context, org *CreateOrganizationCommand) error
|
||||
Update(ctx context.Context, condition database.Condition, changes ...database.Change) (int64, error)
|
||||
Delete(ctx context.Context, condition database.Condition) (int64, error)
|
||||
|
||||
|
Reference in New Issue
Block a user