fix: uncomment conditions that handle guest access for desk
This commit is contained in:
parent
7eee5c1a35
commit
aa8f7cc3c5
1 changed files with 4 additions and 4 deletions
|
|
@ -12,10 +12,10 @@ from frappe import _
|
|||
import frappe.sessions
|
||||
|
||||
def get_context(context):
|
||||
# if frappe.session.user == "Guest":
|
||||
# frappe.throw(_("Log in to access this page."), frappe.PermissionError)
|
||||
# elif frappe.db.get_value("User", frappe.session.user, "user_type") == "Website User":
|
||||
# frappe.throw(_("You are not permitted to access this page."), frappe.PermissionError)
|
||||
if frappe.session.user == "Guest":
|
||||
frappe.throw(_("Log in to access this page."), frappe.PermissionError)
|
||||
elif frappe.db.get_value("User", frappe.session.user, "user_type") == "Website User":
|
||||
frappe.throw(_("You are not permitted to access this page."), frappe.PermissionError)
|
||||
|
||||
hooks = frappe.get_hooks()
|
||||
try:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue