Sha256: 5c210e07f7e41b57d77ed6147d9af45a5858e50cff92ce568d2a87f3dbd9a7c2

Contents?: true

Size: 581 Bytes

Versions: 1

Compression:

Stored size: 581 Bytes

Contents

module NxtSupport
  class Email
    # We enforce
    #  (1) Exactly one '@' char prepended and appended by other text
    #  (2) No whitespace characters
    #  (3) At least one non-whitespace character before the '@' character
    #  (4) No dot ('.') character directly after the '@' character
    #  (5) A hostname after the '@' character of at least one non-whitespace characters length
    #  (6) At least one top level domain ending (e.g. '.com') after the hostname, separated from the hostname by a dot ('.')
    REGEXP = /\A[^@\s]+@([^\.@\s]+\.)+[^@\s]+\z/.freeze
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
nxt_support-0.1.15 lib/nxt_support/models/email.rb