wip
This commit is contained in:
@@ -39,13 +39,17 @@ export class LoginWithEmailUseCase {
|
||||
}
|
||||
|
||||
// Create session
|
||||
const authenticatedUser: AuthenticatedUserDTO = {
|
||||
const authenticatedUserBase: AuthenticatedUserDTO = {
|
||||
id: user.id,
|
||||
displayName: user.displayName,
|
||||
email: user.email,
|
||||
primaryDriverId: user.primaryDriverId,
|
||||
};
|
||||
|
||||
const authenticatedUser: AuthenticatedUserDTO =
|
||||
user.primaryDriverId !== undefined
|
||||
? { ...authenticatedUserBase, primaryDriverId: user.primaryDriverId }
|
||||
: authenticatedUserBase;
|
||||
|
||||
return this.sessionPort.createSession(authenticatedUser);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user