[fix] call apply price list, apply pricing rule only if price list is mentioned or there are items in the table
diff --git a/erpnext/stock/get_item_details.py b/erpnext/stock/get_item_details.py
index 6c6f84b..71bc64a 100644
--- a/erpnext/stock/get_item_details.py
+++ b/erpnext/stock/get_item_details.py
@@ -69,7 +69,7 @@
 
 	if args.get("is_subcontracted") == "Yes":
 		out.bom = get_default_bom(args.item_code)
-		
+
 	return out
 
 def process_args(args):
@@ -427,6 +427,9 @@
 		return result.currency
 
 def get_price_list_currency_and_exchange_rate(args):
+	if not args.price_list:
+		return {}
+
 	price_list_currency = get_price_list_currency(args.price_list)
 	plc_conversion_rate = args.plc_conversion_rate