Fix new clippy lint

This commit is contained in:
Jonas Platte 2023-07-31 10:27:25 +02:00
parent e9189392b2
commit bb20ba0711
No known key found for this signature in database
GPG Key ID: AAA7A61F696C3E0C
2 changed files with 2 additions and 2 deletions

View File

@ -84,7 +84,7 @@ impl<A, K: ?Sized> Eq for KeyId<A, K> {}
impl<A, K: ?Sized> PartialOrd for KeyId<A, K> {
fn partial_cmp(&self, other: &Self) -> Option<Ordering> {
PartialOrd::partial_cmp(self.as_str(), other.as_str())
Some(self.cmp(other))
}
}

View File

@ -123,7 +123,7 @@ impl PartialOrd for RoomVersionId {
/// specification. This implementation only exists to be able to use `RoomVersionId`s or
/// types containing `RoomVersionId`s as `BTreeMap` keys.
fn partial_cmp(&self, other: &RoomVersionId) -> Option<Ordering> {
self.as_str().partial_cmp(other.as_str())
Some(self.cmp(other))
}
}