diff --git a/guides/building-a-middleware-from-scratch.md b/guides/building-a-middleware-from-scratch.md index 6a47ac11..6bbfb66a 100644 --- a/guides/building-a-middleware-from-scratch.md +++ b/guides/building-a-middleware-from-scratch.md @@ -323,7 +323,7 @@ where // long and we have to return an error. match this.sleep.poll(cx) { Poll::Ready(()) => { - // Our time is up, but error do we return?! + // Our time is up, but what error do we return?! todo!() } Poll::Pending => { @@ -377,7 +377,7 @@ and can use `match` to get at the exact error, the approach has three issues: 1. In practice its common to nest lots of middleware. That would make the final error enum very large. Its not unlikely to look something like `BufferError>>`. Pattern matching on - such a type (to for example determine if the error is retry-able) is very + such a type (to, for example, determine if the error is retry-able) is very tedious. 2. If we change the order our middleware are applied in we also change the final error type meaning we have to update our pattern matches.