driver to user id

This commit is contained in:
2026-01-07 13:26:31 +01:00
parent 0db80fa98d
commit 94d60527f4
27 changed files with 856 additions and 1170 deletions

View File

@@ -10,8 +10,9 @@ import { InMemoryAuthRepository } from '@adapters/identity/persistence/inmemory/
import { InMemoryUserRepository } from '@adapters/identity/persistence/inmemory/InMemoryUserRepository';
import { InMemoryPasswordHashingService } from '@adapters/identity/services/InMemoryPasswordHashingService';
import { InMemoryMagicLinkRepository } from '@adapters/identity/persistence/inmemory/InMemoryMagicLinkRepository';
import { InMemoryCompanyRepository } from '@adapters/identity/persistence/inmemory/InMemoryCompanyRepository';
import { AUTH_REPOSITORY_TOKEN, PASSWORD_HASHING_SERVICE_TOKEN, USER_REPOSITORY_TOKEN, MAGIC_LINK_REPOSITORY_TOKEN } from '../identity/IdentityPersistenceTokens';
import { AUTH_REPOSITORY_TOKEN, PASSWORD_HASHING_SERVICE_TOKEN, USER_REPOSITORY_TOKEN, MAGIC_LINK_REPOSITORY_TOKEN, COMPANY_REPOSITORY_TOKEN } from '../identity/IdentityPersistenceTokens';
@Module({
imports: [LoggingModule],
@@ -48,7 +49,11 @@ import { AUTH_REPOSITORY_TOKEN, PASSWORD_HASHING_SERVICE_TOKEN, USER_REPOSITORY_
useFactory: (logger: Logger) => new InMemoryMagicLinkRepository(logger),
inject: ['Logger'],
},
{
provide: COMPANY_REPOSITORY_TOKEN,
useClass: InMemoryCompanyRepository,
},
],
exports: [USER_REPOSITORY_TOKEN, AUTH_REPOSITORY_TOKEN, PASSWORD_HASHING_SERVICE_TOKEN, MAGIC_LINK_REPOSITORY_TOKEN],
exports: [USER_REPOSITORY_TOKEN, AUTH_REPOSITORY_TOKEN, PASSWORD_HASHING_SERVICE_TOKEN, MAGIC_LINK_REPOSITORY_TOKEN, COMPANY_REPOSITORY_TOKEN],
})
export class InMemoryIdentityPersistenceModule {}