Skip to content

Commit

Permalink
feat: update ton wallet address
Browse files Browse the repository at this point in the history
  • Loading branch information
harisato committed Sep 23, 2024
1 parent 562fb8c commit 3a37579
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions src/modules/user/user.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -226,16 +226,17 @@ export class UserService {
},
};

const pictureFile = files.filter((f) => f.fieldname === 'picture')[0];
if (pictureFile) {
const pictureUrl = await this.filesService.uploadImageToS3(
`user-${userId}`,
pictureFile
);

variables._set.picture = pictureUrl;
if (files && files.length > 0) {
const pictureFile = files.filter((f) => f.fieldname === 'picture')[0];
if (pictureFile) {
const pictureUrl = await this.filesService.uploadImageToS3(
`user-${userId}`,
pictureFile
);

variables._set.picture = pictureUrl;
}
}

const result = await this.userGraphql.updateUserProfile(token, variables);

return result;
Expand Down

0 comments on commit 3a37579

Please sign in to comment.