aboutsummaryrefslogtreecommitdiff
path: root/examples/windmark.rs
diff options
context:
space:
mode:
authorFuwn <[email protected]>2022-07-09 01:41:19 +0000
committerFuwn <[email protected]>2022-07-09 01:41:19 +0000
commitd806185bdd41cd89159f5ab729710d84bbae2265 (patch)
tree9d984c80f8f0de526523a320d562f8c3c94748e6 /examples/windmark.rs
parentchore(cargo): republish with --all-features (diff)
downloadwindmark-0.1.19.tar.xz
windmark-0.1.19.zip
feat(response): success with mime responsev0.1.19
Diffstat (limited to 'examples/windmark.rs')
-rw-r--r--examples/windmark.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/examples/windmark.rs b/examples/windmark.rs
index 80b0cba..736eb54 100644
--- a/examples/windmark.rs
+++ b/examples/windmark.rs
@@ -103,6 +103,12 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
}),
);
router.mount(
+ "/specific-mime",
+ Box::new(|_| {
+ Response::SuccessWithMime("hi".to_string(), "text/plain".to_string())
+ }),
+ );
+ router.mount(
"/ip",
Box::new(|context| {
Response::Success(