Skip to content

Commit

Permalink
Solve issue #114
Browse files Browse the repository at this point in the history
Trailing dash in Indian addresses without a postcode
  • Loading branch information
freyfogle committed Sep 30, 2024
1 parent fddd89c commit 3257329
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
3 changes: 3 additions & 0 deletions conf/countries/worldwide.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1077,6 +1077,9 @@ IM:
# http://en.wikipedia.org/wiki/Address_%28geography%29#India
IN:
address_template: *generic12
postformat_replace:
# deal with - but no postcode
- [" -\n","\n"]

# British Indian Ocean Territory - same as UK
IO:
Expand Down
15 changes: 14 additions & 1 deletion testcases/countries/in.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ expected: |
Hyderabad - 500064
Telangana
India
---
description: Indian postcode
components:
Expand All @@ -30,3 +29,17 @@ expected: |
400096
Mahārāshtra
India
---
description: without postcode
components:
city: Pune
country: India
country_code: in
road: Baner
state: Maharashtra
expected: |
Baner
Pune
Maharashtra
India

0 comments on commit 3257329

Please sign in to comment.