Skip to content

Commit 898e5bb

Browse files
authored
Merge pull request #165 from osm-without-borders/add_capital
Add capital
2 parents 7b048fb + 8028518 commit 898e5bb

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ The best way to explore the data (i.e. the coverage, the zones metadata, the hie
3030
You can build cosmogony to extract the regions on your own.
3131

3232
- #### Build
33-
Here are the necessary manual steps to build cosmogony:
33+
Here are the necessary manual steps to build cosmogony :
3434
```bash
3535
curl https://sh.rustup.rs -sSf | sh # intall rust
3636
apt-get install libgeos-dev # install GEOS

src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,9 @@ pub fn is_admin(obj: &OsmObj) -> bool {
3737
&&
3838
rel.tags.get("admin_level").is_some()
3939
}
40+
OsmObj::Node(ref node) => {
41+
node.tags.get("capital").map_or(false, |v| v == "yes")
42+
}
4043
_ => false,
4144
}
4245
}

0 commit comments

Comments
 (0)