Merge branch 'hotfix'
diff --git a/erpnext/__init__.py b/erpnext/__init__.py
index 79a8fe1..06af401 100644
--- a/erpnext/__init__.py
+++ b/erpnext/__init__.py
@@ -2,7 +2,7 @@
from __future__ import unicode_literals
import frappe
-__version__ = '7.2.4'
+__version__ = '7.2.5'
def get_default_company(user=None):
'''Get default company for user'''
diff --git a/erpnext/public/js/controllers/transaction.js b/erpnext/public/js/controllers/transaction.js
index dcbb56b..799730e 100644
--- a/erpnext/public/js/controllers/transaction.js
+++ b/erpnext/public/js/controllers/transaction.js
@@ -349,7 +349,7 @@
me.frm.set_value("letter_head", company_doc.default_letter_head);
}
}
- if (company_doc.default_terms && me.frm.doc.doctype != "Purchase Invoice") {
+ if (company_doc.default_terms && me.frm.doc.doctype != "Purchase Invoice" && frappe.meta.has_field(me.frm.doc.doctype, "tc_name")) {
me.frm.set_value("tc_name", company_doc.default_terms);
}