Sha256: 015a29f044bd0c7b089b266ff5b31f64c58bb745eb85dc06cf0547a5b18f1903

Contents?: true

Size: 217 Bytes

Versions: 6

Compression:

Stored size: 217 Bytes

Contents

module Pinfirmable
  class Pin
    attr_accessor :digits

    def initialize(digits)
      @digits = digits.flatten.join
    end

    def matches_user_pin(user)
      user.pinfirmable_pin == @digits
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
pinfirmable-0.1.5 lib/pinfirmable/pin.rb
pinfirmable-0.1.4 lib/pinfirmable/pin.rb
pinfirmable-0.1.3 lib/pinfirmable/pin.rb
pinfirmable-0.1.2 lib/pinfirmable/pin.rb
pinfirmable-0.1.1 lib/pinfirmable/pin.rb
pinfirmable-0.1.0 lib/pinfirmable/pin.rb