koa 2.16.0 → 2.16.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -257,10 +257,9 @@ function respond(ctx) {
257
257
  // allow bypassing koa
258
258
  if (false === ctx.respond) return;
259
259
 
260
- const res = ctx.res;
261
-
262
- if (!ctx.writable) return res.end();
260
+ if (!ctx.writable) return;
263
261
 
262
+ const res = ctx.res;
264
263
  let body = ctx.body;
265
264
  const code = ctx.status;
266
265
 
package/lib/response.js CHANGED
@@ -275,7 +275,7 @@ module.exports = {
275
275
  if (this.ctx.accepts('html')) {
276
276
  url = escape(url);
277
277
  this.type = 'text/html; charset=utf-8';
278
- this.body = `Redirecting to <a href="${url}">${url}</a>.`;
278
+ this.body = `Redirecting to ${url}.`;
279
279
  return;
280
280
  }
281
281
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "koa",
3
- "version": "2.16.0",
3
+ "version": "2.16.1",
4
4
  "description": "Koa web app framework",
5
5
  "main": "lib/application.js",
6
6
  "exports": {