Skip to content

Commit

Permalink
fix: fail migration due to None type during v13_0.update_returned_qty…
Browse files Browse the repository at this point in the history
…_in_pr_dn (frappe#27430)

* fix: fail migration due to None type

* fix: incorrect key: value pair in filter.

Co-authored-by: Ankush Menat <ankush@iwebnotes.com>
  • Loading branch information
dj12djdjs and ankush authored Sep 11, 2021
1 parent 8337ec9 commit becf471
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion erpnext/patches/v13_0/update_returned_qty_in_pr_dn.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ def execute():
frappe.reload_doc('stock', 'doctype', 'stock_settings')

def update_from_return_docs(doctype):
for return_doc in frappe.get_all(doctype, filters={'is_return' : 1, 'docstatus' : 1}):
for return_doc in frappe.get_all(doctype, filters={'is_return' : 1, 'docstatus' : 1, 'return_against': ('!=', '')}):
# Update original receipt/delivery document from return
return_doc = frappe.get_cached_doc(doctype, return_doc.name)
try:
Expand Down

0 comments on commit becf471

Please sign in to comment.