diff options
| author | Fuwn <[email protected]> | 2022-03-26 09:29:51 +0000 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2022-03-26 09:29:51 +0000 |
| commit | e467552a27a49a9b87462f5963bff6811dabd0e3 (patch) | |
| tree | 980947f4ae0825f5f535d5fdc4a251c4d0246fa9 /examples | |
| parent | refactor(handle): simply further (diff) | |
| download | windmark-e467552a27a49a9b87462f5963bff6811dabd0e3.tar.xz windmark-e467552a27a49a9b87462f5963bff6811dabd0e3.zip | |
feat(response): temporary failure response
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/windmark.rs | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/examples/windmark.rs b/examples/windmark.rs index d719993..391b13e 100644 --- a/examples/windmark.rs +++ b/examples/windmark.rs @@ -60,6 +60,9 @@ fn main() -> std::io::Result<()> { .mount("/test", |_, _, _| { Response::Success("hi there\n=> / back".to_string()) }) + .mount("/temporary-failure", |_, _, _| { + Response::TemporaryFailure("Woops, temporarily...".into()) + }) .mount("/time", |_, _, _| { Response::Success( std::time::UNIX_EPOCH |