fix: Python 3 compatibility fixes

import reduce from functools

Undefined variable
This commit is contained in:
Aditya Hase 2019-05-01 11:48:10 +05:30
parent 7516e7e66e
commit 234d35781c
2 changed files with 2 additions and 1 deletions

View File

@ -3,6 +3,7 @@
# For license information, please see license.txt
from __future__ import unicode_literals
from functools import reduce
import frappe, csv
from frappe import _
from frappe.utils import cstr

View File

@ -292,7 +292,7 @@ def prepare_and_attach_invoice(doc, replace=False):
"content": invoice_xml
})
_file.save()
return file
return _file
@frappe.whitelist()
def generate_single_invoice(docname):