From a87b9cc3bd1023658d7a4b99cd4cfc2bb7871f64 Mon Sep 17 00:00:00 2001 From: Aditya Hase Date: Tue, 19 Feb 2019 23:52:57 +0530 Subject: [PATCH] fix: Clear duplicate entry message (#6961) --- frappe/chat/doctype/chat_profile/chat_profile.py | 1 + 1 file changed, 1 insertion(+) 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))