simple_email_validation 0.1.0 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 64c8d9cae3926629af46f02946f006ac88d91cb2
4
- data.tar.gz: db36efd841c3bdff7dcea5a3c0d932dfd4d70fb2
3
+ metadata.gz: dc84028cc0ec5843b4ae5173cabc0c85b1385a91
4
+ data.tar.gz: 30617b28a99102e5b597c89c667ee77102417ed6
5
5
  SHA512:
6
- metadata.gz: 3c132de6bdc847a60c25b9498bac4130c6f42f0d7295ffea9575eb72a6dae2d63f9f600d8942a172af4e60c81a2cdb8c84e002c458d373c67954bf5758763a1f
7
- data.tar.gz: e0774adf49e15508fd47bc7f7a0e3d2ad414767b273f70373b94a23bdf7d9e92d1b6c3480d5f8aa85cc678934cbf1eb209fefbd02072a1d98e92418244cb1b27
6
+ metadata.gz: e3575e688e9b90ab0bc092650a44e75764e89eee006ee8211fac0d44878fd6f9d21fecb5631359eb6a08c36fe31df29490115a1915d1b7eadc17576983f34226
7
+ data.tar.gz: cab1fda194977724bc7bd7843cdfde02a6059225c8736c8a4e5c8f93ab1d23106b2f9cf26995f6cc7ca205788b3a1b5c2ffc848913f26aab45be7f0068b1a6ae
data/README.md CHANGED
@@ -22,6 +22,8 @@ class User < ActiveRecord::Base
22
22
  end
23
23
  ```
24
24
 
25
+ it conforms to RFC5322
26
+
25
27
  ## Contributing
26
28
 
27
29
  1. Fork it
@@ -3,13 +3,13 @@ class EmailValidator < ActiveModel::EachValidator
3
3
 
4
4
  class << self
5
5
  def valid?(email)
6
- email.match(REG_EXP)
6
+ !!(email.match(REG_EXP))
7
7
  end
8
8
  end
9
9
 
10
10
  def validate_each(record, attribute, value)
11
11
  unless self.class.valid?(value)
12
- record.errors.add(attribute, options[:massage])
12
+ record.errors.add(attribute, options[:message])
13
13
  end
14
14
  end
15
15
  end
@@ -1,3 +1,3 @@
1
1
  module SimpleEmailValidation
2
- VERSION = "0.1.0"
2
+ VERSION = "0.2.0"
3
3
  end
@@ -20,6 +20,7 @@ Gem::Specification.new do |spec|
20
20
  spec.require_paths = ["lib"]
21
21
 
22
22
  spec.add_development_dependency "bundler", "~> 1.12"
23
+ spec.add_development_dependency "pry-byebug", "~> 3.0"
23
24
  spec.add_development_dependency "rake", "~> 10.0"
24
25
  spec.add_development_dependency "rspec", "~> 3.0"
25
26
  spec.add_runtime_dependency "activemodel"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: simple_email_validation
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - ryosuke-endo
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-09-19 00:00:00.000000000 Z
11
+ date: 2016-09-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -24,6 +24,20 @@ dependencies:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
26
  version: '1.12'
27
+ - !ruby/object:Gem::Dependency
28
+ name: pry-byebug
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '3.0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '3.0'
27
41
  - !ruby/object:Gem::Dependency
28
42
  name: rake
29
43
  requirement: !ruby/object:Gem::Requirement