mirror of
https://github.com/Shopify/liquid.git
synced 2026-01-26 12:14:58 +00:00
Fix array has filters referring to some (#1910)
This commit is contained in:
parent
bfe29e11be
commit
040801b32c
@ -456,7 +456,7 @@ module Liquid
|
||||
# Tests if any item in an array has a specific property value.
|
||||
# @liquid_description
|
||||
# This requires you to provide both the property name and the associated value.
|
||||
# @liquid_syntax array | some: string, string
|
||||
# @liquid_syntax array | has: string, string
|
||||
# @liquid_return [boolean]
|
||||
def has(input, property, target_value = nil)
|
||||
filter_array(input, property, target_value, false) { |ary, &block| ary.any?(&block) }
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user