aboutsummaryrefslogtreecommitdiff
path: root/src/https.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/https.rs')
-rw-r--r--src/https.rs9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/https.rs b/src/https.rs
index 7d64e44..e1db42e 100644
--- a/src/https.rs
+++ b/src/https.rs
@@ -100,15 +100,14 @@ async fn handle(
.map(|prefix| path.starts_with(prefix))
.unwrap_or(true)
})
- .min_by_key(|ent| {
+ .max_by_key(|ent| {
(
ent.priority,
- -(ent
- .path_prefix
+ ent.path_prefix
.as_ref()
.map(|x| x.len() as i32)
- .unwrap_or(0)),
- ent.calls.load(Ordering::SeqCst),
+ .unwrap_or(0),
+ -ent.calls.load(Ordering::SeqCst),
)
});