Skip to content

Commit

Permalink
remove name from projection
Browse files Browse the repository at this point in the history
  • Loading branch information
gabriellsh committed Nov 8, 2024
1 parent bb3b9d6 commit f702cb9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/meteor/server/routes/avatar/user.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ export const userAvatarById = async function (request: IncomingMessage, res: Ser

const externalProviderUrl = settings.get<string>('Accounts_AvatarExternalProviderUrl');
if (externalProviderUrl) {
const user = await Users.findOneById<Pick<IUser, 'name' | 'username'>>(requestUserId, { projection: { username: 1, name: 1 } });
const user = await Users.findOneById<Pick<IUser, 'username'>>(requestUserId, { projection: { username: 1 } });

if (!user?.username) {
res.writeHead(404);
Expand Down

0 comments on commit f702cb9

Please sign in to comment.