Update erpnext/regional/saudi_arabia/utils.py

Co-authored-by: Saqib <nextchamp.saqib@gmail.com>
This commit is contained in:
Ahmad
2021-09-17 01:27:37 +05:00
committed by Deepesh Garg
parent 5f7c5bcac8
commit f9770b69b2

View File

@@ -68,7 +68,7 @@ def delete_qr_code_file(doc, method):
if hasattr(doc, 'qr_code'):
if doc.get('qr_code'):
file_doc = frappe.get_list('File', {
'file_url': doc.qr_code
'file_url': doc.get('qr_code')
})
if len(file_doc):
frappe.delete_doc('File', file_doc[0].name)