Skip to content

Commit

Permalink
Handle some implied OSM one-ways. #69
Browse files Browse the repository at this point in the history
  • Loading branch information
dabreegster committed Jan 19, 2025
1 parent e99bfc0 commit 04a6a36
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions backend/src/map_model.rs
Original file line number Diff line number Diff line change
Expand Up @@ -666,6 +666,11 @@ impl Direction {
} else if tags.is("oneway", "-1") {
Self::Backwards
} else {
// https://wiki.openstreetmap.org/wiki/Key:oneway#Implied_oneway_restriction
if tags.is("highway", "motorway") || tags.is("junction", "roundabout") {
return Self::Forwards;
}

Self::BothWays
}
}
Expand Down

0 comments on commit 04a6a36

Please sign in to comment.