Skip to content

Commit c6ac8ac

Browse files
committed
clippy: remove unnecessary map(Oid::from)s
1 parent 10333ca commit c6ac8ac

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

radicle-surf/src/revision.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ impl Revision for &str {
5353
type Error = git2::Error;
5454

5555
fn object_id(&self, _repo: &Repository) -> Result<Oid, Self::Error> {
56-
Oid::from_str(self).map(Oid::from)
56+
Oid::from_str(self)
5757
}
5858
}
5959

@@ -78,7 +78,7 @@ impl Revision for String {
7878
type Error = git2::Error;
7979

8080
fn object_id(&self, _repo: &Repository) -> Result<Oid, Self::Error> {
81-
Oid::from_str(self).map(Oid::from)
81+
Oid::from_str(self)
8282
}
8383
}
8484

0 commit comments

Comments
 (0)