q-koa 8.7.2 → 8.8.0

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.
Files changed (2) hide show
  1. package/core/app.js +3 -0
  2. package/package.json +1 -1
package/core/app.js CHANGED
@@ -146,6 +146,9 @@ class APP {
146
146
  return ctx.ERROR('error')
147
147
  }
148
148
  const appName = url.split('/')[1]
149
+ if (!appName || !(ctx.app[appName] && ctx.app[appName].appConfig)) {
150
+ return ctx.ERROR('error')
151
+ }
149
152
  const { secret, whiteList, _whiteList, tokenKey, expiresIn } =
150
153
  ctx.app[appName] && ctx.app[appName].appConfig
151
154
  ? ctx.app[appName].appConfig.jwt
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "q-koa",
3
- "version": "8.7.2",
3
+ "version": "8.8.0",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {