fix: explicitly check type of form name
This commit is contained in:
parent
f4062b4d7a
commit
eded5eac24
1 changed files with 2 additions and 0 deletions
|
|
@ -158,6 +158,8 @@ def get_context(context):
|
|||
|
||||
# check permissions
|
||||
if frappe.form_dict.name:
|
||||
assert isinstance(frappe.form_dict.name, str)
|
||||
|
||||
if frappe.session.user == "Guest":
|
||||
frappe.throw(
|
||||
_("You need to be logged in to access this {0}.").format(self.doc_type),
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue