forked from Cutlery/immich
* refactor: user repository * refactor: user module * refactor: move database into infra * refactor(cli): use user core * chore: import path * chore: tests
20 lines
698 B
TypeScript
20 lines
698 B
TypeScript
import { Module } from '@nestjs/common';
|
|
import { ShareService } from './share.service';
|
|
import { ShareController } from './share.controller';
|
|
import { SharedLinkEntity } from '@app/infra';
|
|
import { TypeOrmModule } from '@nestjs/typeorm';
|
|
import { SharedLinkRepository, ISharedLinkRepository } from './shared-link.repository';
|
|
|
|
const SHARED_LINK_REPOSITORY_PROVIDER = {
|
|
provide: ISharedLinkRepository,
|
|
useClass: SharedLinkRepository,
|
|
};
|
|
|
|
@Module({
|
|
imports: [TypeOrmModule.forFeature([SharedLinkEntity])],
|
|
controllers: [ShareController],
|
|
providers: [ShareService, SHARED_LINK_REPOSITORY_PROVIDER],
|
|
exports: [SHARED_LINK_REPOSITORY_PROVIDER, ShareService],
|
|
})
|
|
export class ShareModule {}
|