freemail 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/freemail.rb +3 -2
- data/lib/freemail/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 980fa7d9b1c9a78f4624c80568a7a5aa497ab896
|
4
|
+
data.tar.gz: 6f8aec44134e96699f1700af8de032d4d9148df0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7ea7acb81bf6127cfa4817d22fdfa0794a9b3630cf3f397d9777402d5689dee8c04f02aba3bbbc49522073592154269e71242f70964b615ae14cf77201280808
|
7
|
+
data.tar.gz: 60c759f34edcbb418b48c0e04d992cab429b446cade5d739ae94051c3e96d3e1f0e19358b287bb695f1124a3bdc7eca350564d999ff885c570d9dc209b065850
|
data/lib/freemail.rb
CHANGED
@@ -1,8 +1,9 @@
|
|
1
1
|
require 'freemail/version'
|
2
2
|
|
3
3
|
module Freemail
|
4
|
-
|
5
|
-
|
4
|
+
ROOT = File.join(File.dirname(File.expand_path(__FILE__)), '../')
|
5
|
+
DISPOSABLE = Hash[File.readlines("#{ROOT}/data/disposable.txt").map { |d| [d.strip.downcase] }]
|
6
|
+
FREE = Hash[File.readlines("#{ROOT}/data/free.txt").map { |d| [d.strip.downcase] }]
|
6
7
|
|
7
8
|
def self.free?(email)
|
8
9
|
FREE.key?(get_domain(email))
|
data/lib/freemail/version.rb
CHANGED