Skip to content

Commit

Permalink
Use new FlowCtrl for HoppedHandler
Browse files Browse the repository at this point in the history
  • Loading branch information
chrislearn committed Aug 23, 2024
1 parent 1c3148f commit 614688a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions crates/core/src/handler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -275,9 +275,9 @@ impl HoopedHandler {
}
#[async_trait]
impl Handler for HoopedHandler {
async fn handle(&self, req: &mut Request, depot: &mut Depot, res: &mut Response, ctrl: &mut FlowCtrl) {
async fn handle(&self, req: &mut Request, depot: &mut Depot, res: &mut Response, _ctrl: &mut FlowCtrl) {
let inner: Arc<dyn Handler> = self.inner.clone();
ctrl.handlers.extend(self.hoops.iter().chain([&inner]).cloned());
let mut ctrl = FlowCtrl::new(self.hoops.iter().chain([&inner]).cloned().collect());
ctrl.call_next(req, depot, res).await;
}
}
Expand Down

0 comments on commit 614688a

Please sign in to comment.