Module: LAA::FeeCalculator::HasManyable::ClassMethods::Searchable

Defined in:
lib/laa/fee_calculator/has_manyable.rb

Instance Method Summary collapse

Instance Method Details

#find_by(**options) ⇒ Object



14
15
16
17
18
# File 'lib/laa/fee_calculator/has_manyable.rb', line 14

def find_by(**options)
  find do |ostruct|
    options.map { |k, v| ostruct[k].eql?(v) }.all?
  end
end