Skip to content

Commit

Permalink
filter available shipping methods based on tags
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewpbrett committed Sep 16, 2020
1 parent 6eb4305 commit 93c1ea6
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,8 @@ def shipping_methods
available_shipping_methods.keep_if do |shipping_method|
ships_with?(order.distributor.shipping_methods.to_a, shipping_method)
end
applicator = OpenFoodNetwork::TagRuleApplicator.new(order.distributor, "FilterShippingMethods", order.customer.tag_list)
applicator.filter!(available_shipping_methods)
end

def inspect
Expand Down

0 comments on commit 93c1ea6

Please sign in to comment.