From 6245ddb14d0291ff7b581a937e804f871f792c30 Mon Sep 17 00:00:00 2001 From: timwis Date: Thu, 25 Feb 2016 10:18:03 -0500 Subject: [PATCH] where filter uses array for everything --- lib/jekyll/filters.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/jekyll/filters.rb b/lib/jekyll/filters.rb index 55e91ee8..b7c8e6bb 100644 --- a/lib/jekyll/filters.rb +++ b/lib/jekyll/filters.rb @@ -222,7 +222,7 @@ module Jekyll def where(input, property, value) return input unless input.is_a?(Enumerable) input = input.values if input.is_a?(Hash) - input.select { |object| item_property(object, property).to_s == value.to_s or item_property(object, property).include? value.to_s } + input.select { |object| Array(item_property(object, property)).map(&:to_s).include?(value.to_s) } end # Sort an array of objects