q-koa 13.0.5 → 13.0.8

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.
package/core/app.js CHANGED
@@ -1171,7 +1171,9 @@ class APP {
1171
1171
  },
1172
1172
  }
1173
1173
  const $between = {
1174
- check: (param) => Array.isArray(param),
1174
+ check: (param) =>
1175
+ Array.isArray(param) &&
1176
+ param.every((p) => p.includes('now()')),
1175
1177
  result: (param, key) => {
1176
1178
  return {
1177
1179
  [key]: param[key].map(Sequelize.literal),
@@ -153,7 +153,7 @@ exports.login = async (ctx) => {
153
153
  const application = await getAppConfig({ app, config })
154
154
 
155
155
  const loginData = lodash.mergeWith(
156
- app.appConfig.loginData,
156
+ lodash.cloneDeep(app.appConfig.loginData),
157
157
  lodash.get(application, 'loginData', {}),
158
158
  (objValue, srcValue) => {
159
159
  if (lodash.isArray(objValue)) {
@@ -355,9 +355,8 @@ exports.checkLogin = async (ctx) => {
355
355
 
356
356
  if (app.appConfig.loginData) {
357
357
  const application = await getAppConfig({ app, config })
358
-
359
358
  const loginData = lodash.mergeWith(
360
- app.appConfig.loginData,
359
+ lodash.cloneDeep(app.appConfig.loginData),
361
360
  lodash.get(application, 'loginData', {}),
362
361
  (objValue, srcValue) => {
363
362
  if (lodash.isArray(objValue)) {
@@ -365,6 +364,7 @@ exports.checkLogin = async (ctx) => {
365
364
  }
366
365
  }
367
366
  )
367
+
368
368
  const include = includeDefault.filter((i) => {
369
369
  return loginData.excludeInclude.every((m) => {
370
370
  return app.model[m] !== i.model
@@ -444,7 +444,7 @@ exports.mp_login = async (ctx) => {
444
444
  if (app.appConfig.loginData) {
445
445
  const application = await getAppConfig({ app, config })
446
446
  const loginData = lodash.mergeWith(
447
- app.appConfig.loginData,
447
+ lodash.cloneDeep(app.appConfig.loginData),
448
448
  lodash.get(application, 'loginData', {}),
449
449
  (objValue, srcValue) => {
450
450
  if (lodash.isArray(objValue)) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "q-koa",
3
- "version": "13.0.5",
3
+ "version": "13.0.8",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {