fat_fingers 0.1.28 → 0.1.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/fat_fingers.rb +6 -1
- data/test/test_fat_fingers.rb +2 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 7b6296289b057635d8270208857c0e2d548718c4
|
|
4
|
+
data.tar.gz: 38861570ab7b127c63898cebcdad00c2062a779b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: fed3b60932fd28ae5d7dd395c3177b1ec02d17231c7319e1650b9c94cb8d08a77bb4d9d3c0434a0c4e00487d6bebfdc1590d787772fa3d507550e952fa9c4719
|
|
7
|
+
data.tar.gz: de40efd876f319b36c9570e89777553f00cc542f2e698a6062c0e73492372b38a73604147e87d0d43eca6d2dcf90c98b27d03e2e8aa0c90a6d29aabd771b8ccd
|
data/lib/fat_fingers.rb
CHANGED
|
@@ -13,6 +13,7 @@ class String
|
|
|
13
13
|
# Returns the cleaned String.
|
|
14
14
|
def clean_up_typoed_email
|
|
15
15
|
downcase.
|
|
16
|
+
remove_mailto.
|
|
16
17
|
remove_invalid_characters.
|
|
17
18
|
fix_transposed_periods.
|
|
18
19
|
remove_period_around_at_sign.
|
|
@@ -32,7 +33,11 @@ class String
|
|
|
32
33
|
end
|
|
33
34
|
|
|
34
35
|
protected
|
|
35
|
-
|
|
36
|
+
|
|
37
|
+
def remove_mailto
|
|
38
|
+
gsub(/\Amailto:/, "")
|
|
39
|
+
end
|
|
40
|
+
|
|
36
41
|
def remove_invalid_characters
|
|
37
42
|
gsub(/(\s|\#|\'|\"|\\)*/, "").
|
|
38
43
|
gsub(/(\,|\.\.)/, ".").
|
data/test/test_fat_fingers.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: fat_fingers
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.29
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Charlie Park
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2017-
|
|
12
|
+
date: 2017-09-18 00:00:00.000000000 Z
|
|
13
13
|
dependencies: []
|
|
14
14
|
description: Makes sure users don't accidentally create an account for the wrong e-mail
|
|
15
15
|
address. Because 'gmial' isn't actually what they meant to type. Similarly, 'yaho.com',
|