From 120cfa8987ecb3e670614e000df82e0d015698cc Mon Sep 17 00:00:00 2001 From: adnan-td Date: Tue, 13 Aug 2024 22:53:31 +0530 Subject: [PATCH] narrow_banner: Refactor recipient_user in direct message. --- web/src/narrow_banner.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/web/src/narrow_banner.ts b/web/src/narrow_banner.ts index 5c34e7a244..3ff5c12b0b 100644 --- a/web/src/narrow_banner.ts +++ b/web/src/narrow_banner.ts @@ -332,8 +332,9 @@ export function pick_empty_narrow_banner(): NarrowBannerData { }; } if (!first_operand.includes(",")) { + const recipient_user = people.get_by_user_id(user_ids[0]); // You have no direct messages with this person - if (people.is_current_user(first_operand)) { + if (people.is_current_user(recipient_user.email)) { return { title: $t({ defaultMessage: