mirror of
https://github.com/frappe/erpnext.git
synced 2026-08-13 22:51:49 +00:00
fix(stock): log Material Request failure without the rolled-back doc (review)
After rollback(save_point=reorder_mr) discards the just-inserted Material Request, mr.log_error() left a dangling Error Log reference. Use frappe.log_error(title=...).
This commit is contained in:
@@ -290,7 +290,7 @@ def create_material_request(material_requests):
|
||||
except Exception as exception:
|
||||
frappe.db.rollback(save_point="reorder_mr")
|
||||
exceptions_list.append(exception)
|
||||
mr.log_error("Unable to create material request")
|
||||
frappe.log_error(title="Unable to create material request")
|
||||
|
||||
if company_wise_mr:
|
||||
if getattr(frappe.local, "reorder_email_notify", None) is None:
|
||||
|
||||
Reference in New Issue
Block a user