Skip to content

Commit

Permalink
fix: update route without cpf
Browse files Browse the repository at this point in the history
  • Loading branch information
tassyla committed Jul 10, 2024
1 parent c1c0e34 commit ea74ba6
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
1 change: 0 additions & 1 deletion src/modules/users/dtos/IUpdateUserDTO.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ interface IUpdateUserDTO {
name: string;
nickname: string;
email: string;
cpf: string;
profession: string;
specialization: string;
phone: string;
Expand Down
4 changes: 1 addition & 3 deletions src/modules/users/services/UpdateUserService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ interface IRequest {
name: string;
nickname: string;
email: string;
cpf: string;
profession: string;
specialization: string;
phone: string;
Expand All @@ -32,7 +31,7 @@ export default class UpdateUserService {
) { }

public async execute({
id, name, nickname, email, cpf, profession, specialization, phone, password, city, state,
id, name, nickname, email, profession, specialization, phone, password, city, state,
}: IRequest): Promise<Users> {
const userAlreadyExists = await this.usersRepository.findById(id);

Expand All @@ -46,7 +45,6 @@ public async execute({
name,
nickname,
email: email.toLowerCase(),
cpf,
profession,
specialization,
phone,
Expand Down

0 comments on commit ea74ba6

Please sign in to comment.