Skip to content

Commit

Permalink
remove console logs
Browse files Browse the repository at this point in the history
  • Loading branch information
adelinaenache committed May 20, 2024
1 parent bdefc6a commit 4af6ae5
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/user/service/user.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ export class UserService {

async updateProfilePicture(user: User, file: string) {
const type = getMimeType(file);
this.logger.warn(type, file);
if (type !== 'image/jpg' && type !== 'image/jpeg' && type !== 'image/png') {
throw new BadRequestException('Only jpg, jpeg and png are accepted');
}
Expand All @@ -55,7 +56,6 @@ export class UserService {
'base64',
);

console.log('here', file, user);
const putObjectRequest = new PutObjectCommand({
Bucket: process.env.AWS_S3_BUCKET_NAME,
Key: `profile-pictures/${user.id}`,
Expand All @@ -74,7 +74,6 @@ export class UserService {
},
});
} catch (err) {
this.logger.error(err);
throw new InternalServerErrorException(
'Failed to upload profile picture',
);
Expand Down

0 comments on commit 4af6ae5

Please sign in to comment.