Module: Recollect::Array::Endify
- Defined in:
- lib/recollect/array/predicate/endify.rb
Class Method Summary collapse
Class Method Details
.check!(item, iteratee, value) ⇒ Object
5 6 7 8 9 10 11 |
# File 'lib/recollect/array/predicate/endify.rb', line 5 def self.check!(item, iteratee, value) fetched_value = Utility::TryFetchOrBlank[item, iteratee] return false unless fetched_value regex = /#{value}$/ fetched_value.to_s.match?(regex) end |