Skip to content

Commit 4acd39b

Browse files
committed
fix(py3): Convert filter to list
1 parent 72056c2 commit 4acd39b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

erpnext/accounts/doctype/pricing_rule/pricing_rule.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -350,7 +350,7 @@ def filter_pricing_rules(args, pricing_rules):
350350
if len(pricing_rules) > 1:
351351
rate_or_discount = list(set([d.rate_or_discount for d in pricing_rules]))
352352
if len(rate_or_discount) == 1 and rate_or_discount[0] == "Discount Percentage":
353-
pricing_rules = filter(lambda x: x.for_price_list==args.price_list, pricing_rules) \
353+
pricing_rules = list(filter(lambda x: x.for_price_list==args.price_list, pricing_rules)) \
354354
or pricing_rules
355355

356356
if len(pricing_rules) > 1 and not args.for_shopping_cart:

0 commit comments

Comments
 (0)