uk_postcode 2.1.7 → 2.1.8

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: 663b870a601ea6e50e4e29cf1f82f6d0888cc5e3fa4bf7a6bb572299769021ef
4
- data.tar.gz: 7795a517f4c3b3d9410c8df9c8f5494097668a2000c9bf3dac293855082fbec7
3
+ metadata.gz: b22121ef34b0d2604d72d1968d8855507628a02bdca0a6db1be1d465c5482fa1
4
+ data.tar.gz: 66a9ea0feaeb8764f39c2239004c22a6c41eaad38ada46a910d15ca688b4a283
5
5
  SHA512:
6
- metadata.gz: e5b4e63111a8d586282fb74a304f4c33e6181de1ea8ebf1d93e8094a5f4af121de85f01b53eb8289dfe818089ecc7b4ed958e8273f045eb1f82f9ed73625f572
7
- data.tar.gz: 87418d80cc33a4d3431f9f6afc817bbcea8be6389ff78a1fd070e71fa4ffd07d01d22acebf6860f6ff97d0c3d3bfe3b35ed41ee5f86055cd2b6006432c9071a7
6
+ metadata.gz: 50a7aa263eff629a1d7f68a8d51e30ff20b5269eb40da9c39d7b41584c85dc5883bfee57d2c572cc5ad145bc92c2be22325e0e964eeb7d72784b338ba2219a67
7
+ data.tar.gz: a5fbe91cfaa1fd95253734ecb518affd086ae72360f2b8d7ade97d0951b7cb864b75c3d509d96a2cf18d5e498da1661261941a9c6e4c2892803fde26017bdbc6
@@ -1,8 +1,8 @@
1
1
  module UKPostcode
2
2
  COUNTRY_LOOKUP = {
3
- england: /^(?:AL|B[123456789ABDHLNRS]|C(?:A(?:1|2|3|4|5|6(?:4|5(?:BF|F|G|H[TU]|L[GHJLNPQRSTUWXYZ]|N|P|Q|R|S|T|U|W|X|Y)|6|7)|7|8|9)|B|H(?:1(?:1|2|3|4(?:A|B|D|E|F|G|H|J|L|N|P|Q[ABDFGHJNPQRSTUWX]|R|S|W|X|Y|Z)|5|6(?:A|B[DEFGHJUW]|D[ABEFGHLNPQRSTUWXYZ]|E[ADEFGH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HJLNPQRSTUXYZ]|P|Q[ABDEFGHJLNPQRSTUWXZ]|R|S|T[ABDEFGHJLPQRSTUWXYZ]|U|W[ADFG]|X|Y))|56|0|1(?:0|1|7|8(?:A|B|D[ABDEFGHJPQRSTUWXYZ]|E[ABDEFGHJLNQSTUXYZ]|F[ABDGJ]|G|H|J[ABDEFGHJZ]|L|N|P|Q|R|S|T|W|X|Z)|9)|3|4)|5(?:0J[JLN]|9(?:A[RSTUWXYZ]|B[ABDEFGHJLNPQSTUW]|EU|FB|G[NR]|LD|SB))|78PS|95JP)))/,
6
6
  channel_islands: /^(?:GY|J)/,
7
7
  isle_of_man: /^IM/,
8
8
  northern_ireland: /^BT/
@@ -1,3 +1,3 @@
1
1
  module UKPostcode
2
- VERSION = "2.1.7"
2
+ VERSION = "2.1.8"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: uk_postcode
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.7
4
+ version: 2.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Paul Battley
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-11-26 00:00:00.000000000 Z
11
+ date: 2022-06-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake