narrow_banner: Refactor recipient_user in direct message.

This commit is contained in:
adnan-td 2024-08-13 22:53:31 +05:30 committed by Tim Abbott
parent ccb65795d9
commit 120cfa8987
1 changed files with 2 additions and 1 deletions

View File

@ -332,8 +332,9 @@ export function pick_empty_narrow_banner(): NarrowBannerData {
}; };
} }
if (!first_operand.includes(",")) { if (!first_operand.includes(",")) {
const recipient_user = people.get_by_user_id(user_ids[0]);
// You have no direct messages with this person // You have no direct messages with this person
if (people.is_current_user(first_operand)) { if (people.is_current_user(recipient_user.email)) {
return { return {
title: $t({ title: $t({
defaultMessage: defaultMessage: