fix: remove panics and unblock flows
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
use nostr::prelude::*;
|
||||
|
||||
/// Compare git URLs ignoring scheme, trailing `.git` and path slashes,
|
||||
/// so a grasp announce URL matches its https origin.
|
||||
/// Compares git URLs ignoring scheme, trailing `.git` and slashes, so grasp matches https.
|
||||
pub fn same_repo_url(a: &str, b: &str) -> bool {
|
||||
match (url_identity(a), url_identity(b)) {
|
||||
(Some(a), Some(b)) => a == b,
|
||||
|
||||
@@ -4,7 +4,7 @@ pub fn sort_newest_first(events: &mut [Event]) {
|
||||
events.sort_by(|a, b| {
|
||||
b.created_at
|
||||
.cmp(&a.created_at)
|
||||
.then_with(|| b.id.to_hex().cmp(&a.id.to_hex()))
|
||||
.then_with(|| b.id.cmp(&a.id))
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user