Error saving in purchase order

Hi all
got an update for system with develop version but unable to save the purchase order below is the traceback


Traceback (most recent call last):
  File "/opt/bench/erpnext/apps/frappe/frappe/desk/form/save.py", line 19, in savedocs
    doc.submit()
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 841, in submit
    self._submit()
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 830, in _submit
    self.save()
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 260, in save
    return self._save(*args, **kwargs)
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 311, in _save
    self.run_post_save_methods()
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 901, in run_post_save_methods
    self.run_method("on_submit")
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 765, in run_method
    out = Document.hook(fn)(self, *args, **kwargs)
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 1040, in composer
    return composed(self, method, *args, **kwargs)
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 1023, in runner
    add_to_return_value(self, fn(self, *args, **kwargs))
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 759, in 
    fn = lambda self, *args, **kwargs: getattr(self, method)(*args, **kwargs)
  File "/opt/bench/erpnext/apps/erpnext/erpnext/buying/doctype/purchase_order/purchase_order.py", line 214, in on_submit
    self.validate_budget()
  File "/opt/bench/erpnext/apps/erpnext/erpnext/controllers/buying_controller.py", line 479, in validate_budget
    }, self.company)
  File "/opt/bench/erpnext/apps/erpnext/erpnext/accounts/doctype/budget/budget.py", line 87, in validate_expense_against_budget
    args.cost_center, args.account = get_item_details(args)
  File "/opt/bench/erpnext/apps/erpnext/erpnext/accounts/doctype/budget/budget.py", line 272, in get_item_details
    {'parent': args.item_code, 'company': args.get('company')}, ['buying_cost_center', 'expense_account'])
TypeError: 'NoneType' object is not iterable

Traceback (most recent call last):
  File "/opt/bench/erpnext/apps/frappe/frappe/app.py", line 62, in application
    response = frappe.handler.handle()
  File "/opt/bench/erpnext/apps/frappe/frappe/handler.py", line 22, in handle
    data = execute_cmd(cmd)
  File "/opt/bench/erpnext/apps/frappe/frappe/handler.py", line 53, in execute_cmd
    return frappe.call(method, **frappe.form_dict)
  File "/opt/bench/erpnext/apps/frappe/frappe/__init__.py", line 942, in call
    return fn(*args, **newargs)
  File "/opt/bench/erpnext/apps/frappe/frappe/desk/form/save.py", line 19, in savedocs
    doc.submit()
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 841, in submit
    self._submit()
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 830, in _submit
    self.save()
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 260, in save
    return self._save(*args, **kwargs)
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 311, in _save
    self.run_post_save_methods()
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 901, in run_post_save_methods
    self.run_method("on_submit")
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 765, in run_method
    out = Document.hook(fn)(self, *args, **kwargs)
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 1040, in composer
    return composed(self, method, *args, **kwargs)
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 1023, in runner
    add_to_return_value(self, fn(self, *args, **kwargs))
  File "/opt/bench/erpnext/apps/frappe/frappe/model/document.py", line 759, in 
    fn = lambda self, *args, **kwargs: getattr(self, method)(*args, **kwargs)
  File "/opt/bench/erpnext/apps/erpnext/erpnext/buying/doctype/purchase_order/purchase_order.py", line 214, in on_submit
    self.validate_budget()
  File "/opt/bench/erpnext/apps/erpnext/erpnext/controllers/buying_controller.py", line 479, in validate_budget
    }, self.company)
  File "/opt/bench/erpnext/apps/erpnext/erpnext/accounts/doctype/budget/budget.py", line 87, in validate_expense_against_budget
    args.cost_center, args.account = get_item_details(args)
  File "/opt/bench/erpnext/apps/erpnext/erpnext/accounts/doctype/budget/budget.py", line 272, in get_item_details
    {'parent': args.item_code, 'company': args.get('company')}, ['buying_cost_center', 'expense_account'])
TypeError: 'NoneType' object is not iterable

updated the warehouse account
& command frappe.db.get_value("Account", account, ["account_currency", "company"])
retuns with NameError: name 'account' is not defined

Pushed a fix for the above error.

Did not understand your query here.