From 84b93414d0a61b4a8f535c3befcefa7b0061d4fa Mon Sep 17 00:00:00 2001 From: Saurabh Date: Tue, 31 Mar 2020 15:57:39 +0530 Subject: [PATCH] fix: typo --- erpnext/crm/doctype/lead/lead.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/crm/doctype/lead/lead.py b/erpnext/crm/doctype/lead/lead.py index 04f21ffb74..eb9f86076c 100644 --- a/erpnext/crm/doctype/lead/lead.py +++ b/erpnext/crm/doctype/lead/lead.py @@ -137,7 +137,7 @@ class Lead(SellingController): # skipping country since the system auto-sets it from system defaults address = frappe.new_doc("Address") - mandatory_fields = [ df.fieldname for df in doc.meta.fields if df.reqd ] + mandatory_fields = [ df.fieldname for df in address.meta.fields if df.reqd ] if not all([self.get(field) for field in mandatory_fields]): frappe.msgprint(_('Missing mandatory fields in address. \