Merge pull request #699 from PlasmaPower/patch-2

Correct ctx.assert documentation parameter order (v2.x)
master
Yiyu He 2016-03-28 01:25:09 +08:00
commit 177b599fd5
1 changed files with 1 additions and 1 deletions

View File

@ -119,7 +119,7 @@ ctx.throw('access_denied', { user: user });
koa uses [http-errors](https://github.com/jshttp/http-errors) to create errors.
### ctx.assert(value, [msg], [status], [properties])
### ctx.assert(value, [status], [msg], [properties])
Helper method to throw an error similar to `.throw()`
when `!value`. Similar to node's [assert()](http://nodejs.org/api/assert.html)