fix: variable declaration
diff --git a/erpnext/selling/doctype/quotation/quotation.js b/erpnext/selling/doctype/quotation/quotation.js
index 7fecd4b..1223449 100644
--- a/erpnext/selling/doctype/quotation/quotation.js
+++ b/erpnext/selling/doctype/quotation/quotation.js
@@ -53,8 +53,11 @@
 	}
 	refresh(doc, dt, dn) {
 		super.refresh(doc, dt, dn);
-		doctype = doc.quotation_to == 'Customer' ? 'Customer':'Lead';
-		frappe.dynamic_link = {doc: this.frm.doc, fieldname: 'party_name', doctype: doctype}
+		frappe.dynamic_link = {
+			doc: this.frm.doc,
+			fieldname: 'party_name',
+			doctype: doc.quotation_to == 'Customer' ? 'Customer' : 'Lead',
+		};
 
 		var me = this;