Skip to content

Commit

Permalink
fix: Update default avatar #173
Browse files Browse the repository at this point in the history
  • Loading branch information
seheon99 committed Dec 10, 2021
1 parent 60dfbdc commit f0f8c51
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion backend/src/users/users.resolver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,12 @@ export class UsersResolver {
@SiteRoles(UserRole.ADMIN)
async updateDefaultAvatar(
@Args('file', { type: () => GraphQLUpload }) file: FileUpload,
) {}
) {
return (
(await this.usersService.deleteDefaultAvatar()) &&
(await this.usersService.createDefaultAvatar(file))
);
}

@Mutation((returns) => ID)
async createDummyUser(): Promise<string> {
Expand Down

0 comments on commit f0f8c51

Please sign in to comment.