refactor to adapters
This commit is contained in:
19
core/identity/domain/repositories/IAuthRepository.ts
Normal file
19
core/identity/domain/repositories/IAuthRepository.ts
Normal file
@@ -0,0 +1,19 @@
|
||||
import { EmailAddress } from '../value-objects/EmailAddress';
|
||||
import { User } from '../entities/User';
|
||||
|
||||
/**
|
||||
* Domain Repository: IAuthRepository
|
||||
*
|
||||
* Repository interface for authentication operations.
|
||||
*/
|
||||
export interface IAuthRepository {
|
||||
/**
|
||||
* Find user by email
|
||||
*/
|
||||
findByEmail(email: EmailAddress): Promise<User | null>;
|
||||
|
||||
/**
|
||||
* Save a user
|
||||
*/
|
||||
save(user: User): Promise<void>;
|
||||
}
|
||||
Reference in New Issue
Block a user