feat: safely parse exception
diff --git a/erpnext/utilities/doctype/rename_tool/rename_tool.js b/erpnext/utilities/doctype/rename_tool/rename_tool.js
index 5a2d249..b8203f4 100644
--- a/erpnext/utilities/doctype/rename_tool/rename_tool.js
+++ b/erpnext/utilities/doctype/rename_tool/rename_tool.js
@@ -33,8 +33,10 @@
let html = r.message.join("<br>");
if (r.exc) {
- r.exc = JSON.parse(r.exc);
- html += "<br>" + r.exc.join("<br>");
+ r.exc = frappe.utils.parse_json(r.exc);
+ if (Array.isArray(r.exc)) {
+ html += "<br>" + r.exc.join("<br>");
+ }
}
frm.get_field("rename_log").$wrapper.html(html);