Commit Graph

17 Commits

Author SHA1 Message Date
Jonathan Ong e6cd31ce2f add tests for exposing app-specific prototypes 2013-11-13 18:41:40 -08:00
TJ Holowaychuk c1bed668bd remove app.context() for now
get away from promoting the extension of prototypes, aside
from it looking better there isnt really a compelling reason
to allow this
2013-11-07 17:05:26 -08:00
TJ Holowaychuk 2d35cdff50 add new style middleware support through @jonathanong's koa-compose patch 2013-11-07 16:15:47 -08:00
Jonathan Ong 4aa75a1164 cleanup trailing whitespace in .js files 2013-10-05 12:27:15 -07:00
TJ Holowaychuk 11913f5e4e add ctx.body= setter
this prevents a bunch of redundant checks that middleware may need to
check response length, type etc. the less code floating around based
on our supported response body types the better, giving us more freedom
to change these as needed, and just less error-prone code in general.
2013-09-14 15:54:17 -07:00
TJ Holowaychuk 04f4d72692 add charset support to ctx.type= 2013-09-14 14:48:33 -07:00
TJ Holowaychuk fc25b79b99 add err.expose check for response handler to expose the err.message 2013-09-12 08:05:50 -07:00
TJ Holowaychuk 091d5010cd add ENOENT err.code support for 404 2013-09-08 12:11:02 -07:00
TJ Holowaychuk 228c38cf3e fix text/plain response for 500 errors 2013-09-08 12:07:50 -07:00
TJ Holowaychuk 92b741ac0a remove socket error handling, use server "clientError" 2013-09-08 11:44:45 -07:00
TJ Holowaychuk 2fe83a4e3d add failing socket error handling test 2013-09-08 11:41:43 -07:00
TJ Holowaychuk 42f5aa1e61 add app "error" test 2013-09-08 09:37:19 -07:00
TJ Holowaychuk 3758f4b675 use app.listen() in tests 2013-09-01 15:07:54 -07:00
TJ Holowaychuk 2de010ca47 add err.status support. Closes #20 2013-08-21 19:47:56 -07:00
TJ Holowaychuk d9e8bb711e misc 2013-08-18 11:16:02 -07:00
Jonathan Ong 978f581099 app.context: extend the context with your own properties 2013-08-17 16:58:53 -07:00
TJ Holowaychuk 9e167c5ed9 Initial commit 2013-08-17 00:15:57 -07:00