aboutsummaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorFuwn <[email protected]>2023-03-31 23:55:20 +0000
committerFuwn <[email protected]>2023-03-31 23:55:20 +0000
commit687f3778f2fed2fe4aba8027c215ce91c54648ed (patch)
tree3358e7db7f4287bcc7bc2e8deeb22e94bfeaffae /examples
parentfix(cargo): response-macros feature flag (diff)
downloadwindmark-687f3778f2fed2fe4aba8027c215ce91c54648ed.tar.xz
windmark-687f3778f2fed2fe4aba8027c215ce91c54648ed.zip
feat(router): expose response to post-route callback
Diffstat (limited to 'examples')
-rw-r--r--examples/windmark.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/examples/windmark.rs b/examples/windmark.rs
index 4507048..e5dcd52 100644
--- a/examples/windmark.rs
+++ b/examples/windmark.rs
@@ -85,7 +85,8 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
)
}));
router.set_post_route_callback(Box::new(|context, content| {
- *content = content.replace("Welcome!", "Welcome to Windmark!");
+ content.content =
+ content.content.replace("Welcome!", "Welcome to Windmark!");
info!(
"closed connection from {}",