/**
 * @aurora-catalyst-generated
 * @source cliter/iam/role.aurora.yaml
 */
import { IamSequelizeRoleRepository } from '@app/iam/role';
import { HandlerMeta } from '@aurorajs.dev/core-back';
import { Injectable } from '@nestjs/common';

@Injectable()
export class IamCreateRoleService {
  constructor(private readonly repository: IamSequelizeRoleRepository) {}

  async main(payload: any, handlerMeta?: HandlerMeta): Promise<void> {
    await this.repository.create(payload, {
      createOptions: handlerMeta?.repositoryOptions,
    });
  }
}
