diff --git a/src/position.rs b/src/position.rs index 3e26ba1..a1be508 100644 --- a/src/position.rs +++ b/src/position.rs @@ -109,7 +109,7 @@ pub(crate) async fn resolve_address(address: String) -> Result { let points: Vec> = osm.forward(&address)?; points - .get(0) + .first() .ok_or(Error::NoPositionFound) .map(Position::from) })