From e75a84f34b6c9ffcffd476d1152ade874c2695e5 Mon Sep 17 00:00:00 2001 From: Matt Holt Date: Mon, 19 Jan 2015 17:17:44 -0700 Subject: [PATCH] Finished a sentence --- Middleware.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Middleware.md b/Middleware.md index 4393758..9a5499b 100644 --- a/Middleware.md +++ b/Middleware.md @@ -51,7 +51,6 @@ func MyMiddleware(p parser) Middleware { When `caddy` is run and the config file is parsed and found to use a middleware, that middleware is unwrapped one piece at a time, to eventually expose the underlying handler, which is ready to use thanks to Go closures. (The handler chain is pre-compiled so it doesn't have to do that for every request.) -That's all there is to it! ## Creating new middleware @@ -62,7 +61,7 @@ So how do you start writing middleware? There are two main things to do: 1. Write the middleware code 2. Register it with a certain directive in `init()` -When the server starts up, the middle +When the server starts up, it unwraps each middleware down to the actual handlers one piece at a time. (Middleware that aren't needed won't be invoked.) ### Parsing