diff options
| author | Fuwn <[email protected]> | 2022-03-27 04:20:30 +0000 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2022-03-27 04:20:30 +0000 |
| commit | 299f53da9ee08c8b326bd913c5911a234e50726d (patch) | |
| tree | 62f3a8f3b5975a88c1306a041796da12cf324458 /examples/windmark.rs | |
| parent | feat(response): implement many more responses (diff) | |
| download | windmark-299f53da9ee08c8b326bd913c5911a234e50726d.tar.xz windmark-299f53da9ee08c8b326bd913c5911a234e50726d.zip | |
feat(response): add remaining responses (redirect)
Diffstat (limited to 'examples/windmark.rs')
| -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 1cccd70..e1e576e 100644 --- a/examples/windmark.rs +++ b/examples/windmark.rs @@ -108,6 +108,9 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> { } }) .mount("/error", |_| Response::CertificateNotValid("no".into())) + .mount("/redirect", |_| { + Response::PermanentRedirect("gemini://localhost/test".into()) + }) .run() .await } |