phony 2.20.8 → 2.20.10

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
  SHA256:
3
- metadata.gz: a9beecb3c5ba9d3ca599f0a3284aa82305bb5512d479f0fc55c10467e1e5e3b2
4
- data.tar.gz: b704cd453f22ebd0ca35e838895f706ee662882001c133f1f970d7b8a65338f3
3
+ metadata.gz: 6f77d71a7b1294ad47e7eec9b97384f70dd514040fb7c4d6fb0869dce7570f24
4
+ data.tar.gz: 10322550d30e582b15a761781d4d377d58520e71008087b1956e79e82ba61278
5
5
  SHA512:
6
- metadata.gz: c611f80164333973c6f3193f8997aaffefb492eb7417dc8a603d7adcfd5183d8c474806e1cd85e521f97078e36adecc3cbb43c50ee8062f40f994400324212aa
7
- data.tar.gz: 2fd3068506fa93bba120e6c62eb49055bad27fee5725dc665c10112d1c8b1a1bbab148347dbda0e3d6d9e60885f4df8df56c173e56966a34544dd36cab5d5021
6
+ metadata.gz: 6f068f7840b8068bca4d1d23bfd78317169d941988480eedc05a195e68f96386cd6490d3f4b42975bf2e5d8f244522e1798556d5308bd9cbb5601ca30d25ec18
7
+ data.tar.gz: 65c4b25791edb9e97c379571021ec145628c86621b8bf1738321de62ec12194a4fe69497280a9857cb749a29547b0411b9a5c2e27b96d470e0a0b87afda1d4a2
@@ -287,6 +287,7 @@ Phony.define do
287
287
  /\A\d{6}\z/ => [4,2],
288
288
  /\A\d{7}\z/ => [4,3],
289
289
  /\A\d{8}\z/ => [4,4],
290
+ /\A\d{9}\z/ => [4,5]
290
291
  ) |
291
292
  one_of(*ndcs_2digit) >> matched_split(
292
293
  /\A\d{4}\z/ => [4],
@@ -494,7 +494,7 @@ Phony.define do
494
494
  one_of('802') >> split(3,3) | # national rate
495
495
  one_of(%w(251 252 271 272 281 282 293)) >> split(3,2) |
496
496
  one_of(%w(21 23 24 26)) >> split(3,3) |
497
- one_of(%w(82 84 86)) >> split(4,3) | # mobile
497
+ one_of(%w(82 83 84 85 86 87)) >> split(4,3) | # mobile
498
498
  one_of('89') >> split(4,3) | # satellite GMPCS
499
499
  one_of('7') >> split(4,4) | # universal access
500
500
  one_of('9') >> split(4,4) | # premium rate
@@ -636,6 +636,9 @@ describe 'plausibility' do
636
636
 
637
637
  Phony.plausible?('+39 803 08163').should be_falsy
638
638
  Phony.plausible?('+39 803 081').should be_truthy
639
+
640
+ Phony.plausible?('+39 06 8323074181').should be_falsy
641
+ Phony.plausible?('+39 06 832307418').should be_truthy
639
642
  end
640
643
 
641
644
  it 'is correct for Russia' do
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: phony
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.20.8
4
+ version: 2.20.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Florian Hanke
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-09-06 00:00:00.000000000 Z
11
+ date: 2023-11-01 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: 'Fast international phone number (E164 standard) normalizing, splitting
14
14
  and formatting. Lots of formatting options: International (+.., 00..), national