Class: Zxcvbn::Matchers::Digits
- Inherits:
-
Object
- Object
- Zxcvbn::Matchers::Digits
- Includes:
- RegexHelpers
- Defined in:
- lib/zxcvbn/matchers/digits.rb
Constant Summary collapse
- DIGITS_REGEX =
/\d{3,}/
Instance Method Summary collapse
Methods included from RegexHelpers
Instance Method Details
#matches(password) ⇒ Object
10 11 12 13 14 15 16 17 |
# File 'lib/zxcvbn/matchers/digits.rb', line 10 def matches(password) result = [] re_match_all(DIGITS_REGEX, password) do |match| match.pattern = 'digits' result << match end result end |