From 5384ee1a5cc1e0f895e651459789863d3157fe27 Mon Sep 17 00:00:00 2001 From: Pooya Parsa Date: Wed, 25 Oct 2017 01:08:31 +0330 Subject: [PATCH] ctx => app.context --- lib/app/utils.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/app/utils.js b/lib/app/utils.js index a091740125..e5d05b0a1a 100644 --- a/lib/app/utils.js +++ b/lib/app/utils.js @@ -125,7 +125,7 @@ export async function setContext(app, context) { if (context.res) app.context.res = context.res app.context.redirect = function (status, path, query) { if (!status) return - ctx._redirected = true // Used in middleware + app.context._redirected = true // Used in middleware // if only 1 or 2 arguments: redirect('/') or redirect('/', { foo: 'bar' }) if (typeof status === 'string' && (typeof path === 'undefined' || typeof path === 'object')) { query = path || {}