Minor fix in patches (#11268)

This commit is contained in:
Nabin Hait 2017-10-21 11:20:18 +05:30 committed by GitHub
parent 12e817bad6
commit c44290955e

View File

@ -12,6 +12,7 @@ def execute():
domains = frappe.db.sql_list("select domain from tabCompany")
if "Education" not in domains:
role = frappe.get_doc("Role", "Instructor")
role.disabled = 1
role.save(ignore_permissions=True)
if frappe.db.exists("Role", "Instructor"):
role = frappe.get_doc("Role", "Instructor")
role.disabled = 1
role.save(ignore_permissions=True)