I have the following class:
export class CreateUserDto {
@IsEmail()
email: string;
@IsNotEmpty()
password: string;
}
But if i sent to my route the following Object:
{
"email": "test@test.com",
"password": "123456789",
"role": "Admin"
}
when i ran in my back-end console.log(body) the role stay in the object. Its possible filter that Object to automatically remove the role field?