From 3c030a23833a650af890491ef6e969f93c94b466 Mon Sep 17 00:00:00 2001 From: Fuwn Date: Mon, 3 Apr 2023 03:06:26 +0000 Subject: refactor(context): callback -> hook --- examples/windmark.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'examples') diff --git a/examples/windmark.rs b/examples/windmark.rs index ed02192..c660f3f 100644 --- a/examples/windmark.rs +++ b/examples/windmark.rs @@ -23,7 +23,7 @@ extern crate log; use windmark::{ response::Response, - context::{CallbackContext, RouteContext}, + context::{HookContext, RouteContext}, success, Router, }; @@ -37,7 +37,7 @@ impl windmark::Module for Clicker { println!("clicker has been attached!"); } - fn on_pre_route(&mut self, context: CallbackContext<'_>) { + fn on_pre_route(&mut self, context: HookContext<'_>) { self.clicks += 1; info!( @@ -47,7 +47,7 @@ impl windmark::Module for Clicker { ); } - fn on_post_route(&mut self, context: CallbackContext<'_>) { + fn on_post_route(&mut self, context: HookContext<'_>) { info!( "clicker has been called post-route on {} with {} clicks!", context.url.path(), -- cgit v1.2.3