Sha256: 1c4b657f7ea22f181a41f2ae083d6af9c8d15ecfb7bf2b872bdd362dbc53bff4

Contents?: true

Size: 293 Bytes

Versions: 2

Compression:

Stored size: 293 Bytes

Contents

module Yoti
  # Process age attribute
  class AgeProcessor
    AGE_PATTERN = "age_(over|under):[1-9][0-9]?[0-9]?"

    # check if the key matches the format age_[over|under]:[1-999]
    def self.is_age_verification(age_field)
        return /#{AGE_PATTERN}/.match?(age_field)
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
yoti-1.3.1 lib/yoti/util/age_processor.rb
yoti-1.3.0 lib/yoti/util/age_processor.rb