From fc8b6f69bd358b7f93177ba37df5aaaf63d3b074 Mon Sep 17 00:00:00 2001 From: Vishnu Ks Date: Wed, 19 Jul 2017 02:59:50 +0530 Subject: [PATCH] messages: Use get_user_including_cross_realm in by_pm_with function. --- zerver/views/messages.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zerver/views/messages.py b/zerver/views/messages.py index 22b90e47a0..4e701612e8 100644 --- a/zerver/views/messages.py +++ b/zerver/views/messages.py @@ -317,7 +317,7 @@ class NarrowBuilder(object): # Personals with other user; include both directions. try: - narrow_profile = get_user_profile_by_email(operand) + narrow_profile = get_user_including_cross_realm(operand, self.user_realm) except UserProfile.DoesNotExist: raise BadNarrowOperator('unknown user ' + operand)