Sha256: 5f4151a1ec91fea3a11d172e18ec0e3fe9cadbf4c8e5ad33c2ae9bdadba67da4
Contents?: true
Size: 581 Bytes
Versions: 8
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 two 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
8 entries across 8 versions & 1 rubygems