fix: open Company Address on a Dunning, which has no items

(cherry picked from commit de8b58ae39)
This commit is contained in:
Mihir Kandoi
2026-10-28 06:57:31 +00:00
committed by Mergify
parent 5e2c49cc60
commit 7b8c72dac7
+1 -1
View File
@@ -111,7 +111,7 @@ $.extend(erpnext.queries, {
}
let filters = { link_doctype: "Company", link_name: doc.company || "" };
const is_drop_ship = doc.items.some((item) => item.delivered_by_supplier);
const is_drop_ship = (doc.items || []).some((item) => item.delivered_by_supplier);
if (is_drop_ship) filters = {};
return {