Skip to content

Commit

Permalink
Merge pull request #802 from The-Commit-Company/800-notification-titl…
Browse files Browse the repository at this point in the history
…e-should-be-updated-for-bot-messages

fix: Message owner name for Bot messages
  • Loading branch information
nikkothari22 authored Apr 2, 2024
2 parents 5e3b03d + 93dbeda commit a1a1bd4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion raven/raven_messaging/doctype/raven_message/raven_message.py
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,10 @@ def get_message_owner_name(self):
"""
Get the full name of the message owner
"""
return frappe.get_cached_value("Raven User", self.owner, "full_name")
if self.is_bot_message:
return frappe.get_cached_value("Raven User", self.bot, "full_name")
else:
return frappe.get_cached_value("Raven User", self.owner, "full_name")

def send_notification_for_direct_message(self):
"""
Expand Down

0 comments on commit a1a1bd4

Please sign in to comment.