Merge pull request #32539 from iamejaaz/36457-report-permission

fix: query report read permission issue
This commit is contained in:
Ejaaz Khan 2025-05-15 18:34:01 +05:30 committed by GitHub
commit 0ca345687d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -708,6 +708,13 @@ def has_match(
# each doctype could have multiple conflicting user permission doctypes, hence using OR
# so that even if one of the sets allows a match, it is true
if match:
if not frappe.has_permission(
doctype=ref_doctype, ptype="read", throw=False, ignore_share_permissions=True
):
match = False
matched_for_doctype = matched_for_doctype or match
if matched_for_doctype: