[fix] Return account currency only if account provided

This commit is contained in:
Nabin Hait 2015-10-04 12:27:46 +05:30
parent 0bc3ca02f3
commit 8954b24b22

View File

@ -210,6 +210,8 @@ def get_parent_account(doctype, txt, searchfield, start, page_len, filters):
def get_account_currency(account):
"""Helper function to get account currency"""
if not account:
return
def generator():
account_currency, company = frappe.db.get_value("Account", account, ["account_currency", "company"])
if not account_currency: