lib/cancan/conditions_matcher.rb
# Matches the block or conditions hash
Matches the block or conditions hash
Matches the block or conditions hash
def condition_match?(attribute, value)
      case value
      when Hash
        hash_condition_match?(attribute, value)
      when Range
        value.cover?(attribute)
      when Enumerable
        value.include?(attribute)
      else
        attribute == value
      end
    end
def condition_match? ( attribute , value ) case value when Hash hash_condition_match? ( attribute , value ) when Range value . cover? ( attribute ) when Enumerable value . include? ( attribute ) else attribute == value end end
Matches the block or conditions hash
Matches the block or conditions hash
attribute
<not_specific>
value
<not_specific>