From d697b8ede4b1e8a5228e3806ddb0666c4e3826b9 Mon Sep 17 00:00:00 2001 From: Ankush Menat Date: Wed, 24 Jan 2024 20:54:43 +0530 Subject: [PATCH] fix: update all users after commit (#24522) --- frappe/core/doctype/role_profile/role_profile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frappe/core/doctype/role_profile/role_profile.py b/frappe/core/doctype/role_profile/role_profile.py index 22a6d0a9a7..c026a4926a 100644 --- a/frappe/core/doctype/role_profile/role_profile.py +++ b/frappe/core/doctype/role_profile/role_profile.py @@ -25,7 +25,7 @@ class RoleProfile(Document): self.name = self.role_profile def on_update(self): - self.queue_action("update_all_users", now=frappe.flags.in_test) + self.queue_action("update_all_users", now=frappe.flags.in_test, enqueue_after_commit=True) def update_all_users(self): """Changes in role_profile reflected across all its user"""