fullname-parser 1.1.1 → 1.1.2

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: 1c6c1b08bafcca5846b1920f92d47aa7688698bc
4
- data.tar.gz: 75bc94883654fe5d2e7e26e6681eababc51c961f
3
+ metadata.gz: 09b6eb370fa0893594a6934ed9e8f55f813b65e4
4
+ data.tar.gz: 8198c830256103491c9c3ed2582d841281c18622
5
5
  SHA512:
6
- metadata.gz: 7dcf64ccdd8ff9e3e400e5f022e0376b7cab6e31a020aec6cdfb760fa142e97b5108715d10fcc283bc958c012713cf531d49e89c351320834cd0a3e6762339d0
7
- data.tar.gz: 2afd18e8d35d0bf28e58092a1a8d7a634d3d1ea2272405460d06baeafc6c7934b6f2669fad67fce16e6702e59b9f9b3729b322c38931d3a9694068f1ec992b60
6
+ metadata.gz: f71b2ad9c81cd2d1b04b081afb46500c7299523a5610cda0748a4fc5e9267614593c7e79565e332b9a922f9eff4758f5d084a0e74f1b4c114b2d01c146e05838
7
+ data.tar.gz: b83e7539c310718571ab58c94e350b16c09d0e9042953144c5fa27b7b6e54d6584dfe8b72af2f74b50617179331e7e8598a849bb0747280589edfc11293840a7
@@ -135,10 +135,11 @@ module Fullname
135
135
  # Henry C.{Harry} Wilson => 'Henry C. Wilson'
136
136
  # Cellestine {Steen} Armstrong => 'Cellestine Armstrong'
137
137
  name.gsub!(/\{.*?\}/, ' ')
138
+
138
139
  # remove exceptional names
139
140
  # ex. "William . D. 'Bill' Beard" => "William D. 'Bill' Beard"
140
141
  # also this regexp can remove
141
- name.gsub!(/\s+[^a-zA-Z]+\s+/, ' ')
142
+ name.gsub!(/\s+[^a-zA-Z,]+\s+/, ' ')
142
143
  # Why we use substitute(sub) comma to whitespace, not global substitute(gsub).
143
144
  # the reason is the substitution applies for suffix splitting, not for replacing
144
145
  # bad data. As we want, convert "Marvene A Gordon, JD" to "Marvene A Gordon JD",
@@ -1,6 +1,6 @@
1
1
 
2
2
  module Fullname
3
3
  module Parser
4
- VERSION = '1.1.1'
4
+ VERSION = '1.1.2'
5
5
  end
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fullname-parser
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - xiaohui