From 64907e5083f9f8ec2453a8d0492c777afa933c8f Mon Sep 17 00:00:00 2001 From: Sushant Nadkar Date: Tue, 5 Jun 2018 10:33:04 +0530 Subject: [PATCH] Validate response message for frappe call (#14343) --- erpnext/public/js/controllers/buying.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/public/js/controllers/buying.js b/erpnext/public/js/controllers/buying.js index 68bb2b8fef..bbeb8e94f1 100644 --- a/erpnext/public/js/controllers/buying.js +++ b/erpnext/public/js/controllers/buying.js @@ -236,7 +236,7 @@ erpnext.buying.BuyingController = erpnext.TransactionController.extend({ items: my_items }, callback: function(r) { - if(r.exc) return; + if(r.exc || !r.message) return; var i = 0; var item_length = cur_frm.doc.items.length;