Skip to content

Commit

Permalink
fix logs
Browse files Browse the repository at this point in the history
  • Loading branch information
Alfagun74 committed Apr 18, 2024
1 parent eb27e8a commit 0584f37
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/modules/users/users.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -362,8 +362,7 @@ export class UsersService implements OnApplicationBootstrap {
const game = await this.gamesService.findByGameIdOrFail(gameId);
user.bookmarked_games.push(game);
this.logger.log(
user,
`User "${user.username}" has bookmarked game ${game.id} (${game.title} (${game.release_date.getUTCFullYear()})).`,
`User "${user.username}" has bookmarked game ${game.id} (${game.title} (${game.release_date?.getUTCFullYear() ?? "????"})).`,
);
return this.userRepository.save(user);
}
Expand All @@ -376,8 +375,9 @@ export class UsersService implements OnApplicationBootstrap {
return bookmark.id !== game.id;
});
this.logger.log(
`User "${user.username}" has unbookmarked game ${game.id} (${game.title} (${game.release_date.getUTCFullYear()})).`,
`User "${user.username}" has unbookmarked game ${game.id} (${game.title} (${game.release_date?.getUTCFullYear() ?? "????"})).`,
);

return this.userRepository.save(user);
}

Expand Down

0 comments on commit 0584f37

Please sign in to comment.