diff options
| author | Fuwn <[email protected]> | 2023-04-06 08:35:28 +0000 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2023-04-06 08:35:28 +0000 |
| commit | 36d26e15f23f2eec98c17aa51209b56005193f1d (patch) | |
| tree | 5e6d83775034b3123d19d1553cbe82ab823ed999 /examples | |
| parent | fix(context): custom parameters format for easy lifetimes (diff) | |
| download | windmark-36d26e15f23f2eec98c17aa51209b56005193f1d.tar.xz windmark-36d26e15f23f2eec98c17aa51209b56005193f1d.zip | |
refactor(context): rename params to parameters
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/windmark.rs | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/examples/windmark.rs b/examples/windmark.rs index 677a694..e7e0a5c 100644 --- a/examples/windmark.rs +++ b/examples/windmark.rs @@ -133,7 +133,10 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> { "/param/:lang", success!( context, - format!("Parameter lang is {}", context.params.get("lang").unwrap()) + format!( + "Parameter lang is {}", + context.parameters.get("lang").unwrap() + ) ), ); router.mount( @@ -142,8 +145,8 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> { context, format!( "{} {}", - context.params.get("first").unwrap(), - context.params.get("last").unwrap() + context.parameters.get("first").unwrap(), + context.parameters.get("last").unwrap() ) ), ); |