Class: Feature::Operation::And
- Inherits:
-
Object
- Object
- Feature::Operation::And
- Defined in:
- lib/toggles/feature/operation/and.rb
Class Method Summary collapse
Class Method Details
.call(entity, attr_name, expected) ⇒ Object
4 5 6 7 8 9 10 11 12 |
# File 'lib/toggles/feature/operation/and.rb', line 4 def self.call(entity, attr_name, expected) expected.all? do |operation, value| if OPERATIONS.include? operation.to_sym OPERATIONS[operation.to_sym].call(entity, attr_name, value) else Operation::Attribute.call(entity, operation, value) end end end |