egg-core
Advanced tools
Comparing version 4.17.3 to 4.17.4
4.17.4 / 2019-12-11 | ||
================== | ||
**fixes** | ||
* [[`2935e16`](http://github.com/eggjs/egg-core/commit/2935e16376cf4c49e049b0e0d9cb7c0bf0b8870a)] - fix: fix before close order (#219) (killa <<killa123@126.com>>) | ||
4.17.3 / 2019-07-07 | ||
@@ -3,0 +9,0 @@ ================== |
@@ -12,3 +12,2 @@ 'use strict'; | ||
const DELEGATE_READY_EVENT = Symbol('Lifecycle#delegateReadyEvent'); | ||
const REGISTER_BEFORE_CLOSE = Symbol('Lifecycle#registerBeforeClose'); | ||
const REGISTER_READY_CALLBACK = Symbol('Lifecycle#registerReadyCallback'); | ||
@@ -105,3 +104,2 @@ const CLOSE_SET = Symbol('Lifecycle#closeSet'); | ||
this[BOOTS] = this[BOOT_HOOKS].map(t => new t(this.app)); | ||
this[REGISTER_BEFORE_CLOSE](); | ||
} | ||
@@ -151,2 +149,7 @@ | ||
} | ||
// function boot hook register after configDidLoad trigger | ||
const beforeClose = boot.beforeClose && boot.beforeClose.bind(boot); | ||
if (beforeClose) { | ||
this.registerBeforeClose(beforeClose); | ||
} | ||
} | ||
@@ -241,11 +244,2 @@ this.triggerDidLoad(); | ||
[REGISTER_BEFORE_CLOSE]() { | ||
for (const boot of this[BOOTS]) { | ||
const beforeClose = boot.beforeClose && boot.beforeClose.bind(boot); | ||
if (beforeClose) { | ||
this.registerBeforeClose(beforeClose); | ||
} | ||
} | ||
} | ||
[REGISTER_READY_CALLBACK]({ scope, ready, timingKeyPrefix, scopeFullName }) { | ||
@@ -252,0 +246,0 @@ if (!is.function(scope)) { |
{ | ||
"name": "egg-core", | ||
"version": "4.17.3", | ||
"version": "4.17.4", | ||
"description": "A core Pluggable framework based on koa", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
124075
2923
1