From 4cead02cb1e8fabb54c18b05aa97f6643b3665aa Mon Sep 17 00:00:00 2001 From: Adam Fowler Date: Fri, 20 Jun 2025 18:25:10 +0100 Subject: [PATCH] Add clarification about router and Application init --- Hummingbird.docc/Articles/MigratingToV2.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Hummingbird.docc/Articles/MigratingToV2.md b/Hummingbird.docc/Articles/MigratingToV2.md index cdfe0203d6..b03d1314e8 100644 --- a/Hummingbird.docc/Articles/MigratingToV2.md +++ b/Hummingbird.docc/Articles/MigratingToV2.md @@ -120,7 +120,7 @@ Instead of creating an application and adding routes to it, in v2 you create a r } } -When we are passing in the router we are actually passing in a type that can build a ``HTTPResponder`` a protocol for a type with one function that takes a request and context and returns a response. +When we are passing in the router we are actually passing in a type that can build a ``HTTPResponder`` a protocol for a type with one function that takes a HTTP request and context and returns a HTTP response. The `Application` creates the HTTP responder from the current state of the router when it is initialized. Any routes added to the router after having created your `Application` will be ignored. ### Router Builder