aboutsummaryrefslogtreecommitdiff
path: root/src/router.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/router.rs')
-rw-r--r--src/router.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/router.rs b/src/router.rs
index 6ae33b0..81eb6c4 100644
--- a/src/router.rs
+++ b/src/router.rs
@@ -421,6 +421,14 @@ impl Router {
}
let mut path = url.path().to_string();
+
+ if self
+ .options
+ .contains(&RouterOption::AllowCaseInsensitiveLookup)
+ {
+ path = path.to_lowercase();
+ }
+
let mut route = self.routes.at(&path);
if route.is_err() {