refactor
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import type { IDriverRepository } from '../../domain/repositories/IDriverRepository';
|
||||
import { Result } from '@core/shared/application/Result';
|
||||
import type { ApplicationErrorCode } from '@core/shared/errors/ApplicationErrorCode';
|
||||
import type { UseCaseOutputPort } from '@core/shared/application';
|
||||
import type { UseCaseOutputPort, UseCase } from '@core/shared/application';
|
||||
|
||||
/**
|
||||
* Input type for retrieving total number of drivers.
|
||||
@@ -17,7 +17,7 @@ export type GetTotalDriversResult = {
|
||||
|
||||
export type GetTotalDriversErrorCode = 'REPOSITORY_ERROR';
|
||||
|
||||
export class GetTotalDriversUseCase {
|
||||
export class GetTotalDriversUseCase implements UseCase<GetTotalDriversInput, void, GetTotalDriversErrorCode> {
|
||||
constructor(
|
||||
private readonly driverRepository: IDriverRepository,
|
||||
private readonly output: UseCaseOutputPort<GetTotalDriversResult>,
|
||||
|
||||
Reference in New Issue
Block a user