aboutsummaryrefslogtreecommitdiff
path: root/examples/fix_path.rs
diff options
context:
space:
mode:
authorFuwn <[email protected]>2025-07-08 05:30:21 +0000
committerFuwn <[email protected]>2025-07-08 05:30:21 +0000
commit3e572d9f4092aad5dda01a7bc87c3c4377e289b1 (patch)
tree9523cccc017225cffdd599e930efb2e518eae285 /examples/fix_path.rs
parentdocs(router_option): Expand documentation (diff)
downloadwindmark-3e572d9f4092aad5dda01a7bc87c3c4377e289b1.tar.xz
windmark-3e572d9f4092aad5dda01a7bc87c3c4377e289b1.zip
feat(router): Add case-insensitive route matching option
Diffstat (limited to 'examples/fix_path.rs')
-rw-r--r--examples/fix_path.rs7
1 files changed, 5 insertions, 2 deletions
diff --git a/examples/fix_path.rs b/examples/fix_path.rs
index 6ea8f9e..f0be8f7 100644
--- a/examples/fix_path.rs
+++ b/examples/fix_path.rs
@@ -17,14 +17,17 @@
//! `cargo run --example fix_path --features response-macros`
+use windmark::router_option::RouterOption;
+
#[windmark::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
windmark::router::Router::new()
.set_private_key_file("windmark_private.pem")
.set_certificate_file("windmark_public.pem")
.add_options(&[
- windmark::router_option::RouterOption::RemoveExtraTrailingSlash,
- windmark::router_option::RouterOption::AddMissingTrailingSlash,
+ RouterOption::RemoveExtraTrailingSlash,
+ RouterOption::AddMissingTrailingSlash,
+ RouterOption::AllowCaseInsensitiveLookup,
])
.mount(
"/close",