fix issues in core
This commit is contained in:
@@ -1,12 +1,11 @@
|
||||
import type { StartAuthCommandDTO } from '../dto/StartAuthCommandDTO';
|
||||
import type { IdentityProviderPort } from '../ports/IdentityProviderPort';
|
||||
import type { IdentityProviderPort, AuthProvider, StartAuthCommand } from '../ports/IdentityProviderPort';
|
||||
import { Result } from '@core/shared/application/Result';
|
||||
import type { ApplicationErrorCode } from '@core/shared/errors/ApplicationErrorCode';
|
||||
import type { UseCaseOutputPort, Logger } from '@core/shared/application';
|
||||
|
||||
export type StartAuthInput = {
|
||||
provider: StartAuthCommandDTO['provider'];
|
||||
returnTo?: StartAuthCommandDTO['returnTo'];
|
||||
provider: AuthProvider;
|
||||
returnTo?: StartAuthCommand['returnTo'];
|
||||
};
|
||||
|
||||
export type StartAuthResult = {
|
||||
@@ -27,7 +26,7 @@ export class StartAuthUseCase {
|
||||
|
||||
async execute(input: StartAuthInput): Promise<Result<void, StartAuthApplicationError>> {
|
||||
try {
|
||||
const command: StartAuthCommandDTO = input.returnTo
|
||||
const command: StartAuthCommand = input.returnTo
|
||||
? {
|
||||
provider: input.provider,
|
||||
returnTo: input.returnTo,
|
||||
|
||||
Reference in New Issue
Block a user