Skip to content

Commit

Permalink
fix: Apply configured perms on address list (#26334) (#26335)
Browse files Browse the repository at this point in the history
(cherry picked from commit 1defbf5)

Co-authored-by: Ankush Menat <ankush@frappe.io>
  • Loading branch information
mergify[bot] and ankush committed May 6, 2024
1 parent 93bf060 commit 4307ab4
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions frappe/contacts/doctype/address/address.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,15 +174,12 @@ def get_address_list(doctype, txt, filters, limit_start, limit_page_length=20, o
from frappe.www.list import get_list

user = frappe.session.user
ignore_permissions = True

if not filters:
filters = []
filters.append(("Address", "owner", "=", user))

return get_list(
doctype, txt, filters, limit_start, limit_page_length, ignore_permissions=ignore_permissions
)
return get_list(doctype, txt, filters, limit_start, limit_page_length)


def has_website_permission(doc, ptype, user, verbose=False):
Expand Down

0 comments on commit 4307ab4

Please sign in to comment.