diff --git a/frappe/chat/doctype/chat_profile/chat_profile.py b/frappe/chat/doctype/chat_profile/chat_profile.py index ca33751519..283494de85 100644 --- a/frappe/chat/doctype/chat_profile/chat_profile.py +++ b/frappe/chat/doctype/chat_profile/chat_profile.py @@ -83,6 +83,7 @@ def create(user, exists_ok = False, fields = None): dprof.user = user dprof.save(ignore_permissions = True) except frappe.DuplicateEntryError: + frappe.clear_messages() if not exists_ok: frappe.throw(_('Chat Profile for User {0} exists.').format(user))