[fix] naming series refactor patch

This commit is contained in:
Nabin Hait 2018-08-28 15:47:08 +05:30
parent 0e7a6856a7
commit 24efd19895

View File

@ -136,7 +136,7 @@ def make_property_setter(doctype, property_name, value):
property_setter.flags.validate_fields_for_doctype = True property_setter.flags.validate_fields_for_doctype = True
try: try:
property_setter.insert() property_setter.insert()
except DuplicateEntryError: except frappe.DuplicateEntryError:
name = "{0}-{1}-{2}-1".format(doctype, fieldname, property) name = "{0}-{1}-{2}-1".format(doctype, fieldname, property)
property_setter.name = name property_setter.name = name
property_setter.insert() property_setter.insert()