Tidying up and refactoring the response builder.

Signed-off-by: Jason Lewis <jason.lewis1991@gmail.com>
Fixing break to authentication middleware where protection is void if no accept header is sent. Fixes #84 and closes #87.

Signed-off-by: Jason Lewis <jason.lewis1991@gmail.com>