koa-generic-session
Advanced tools
Comparing version 1.11.1 to 1.11.3
1.11.3 / 2016-07-24 | ||
================== | ||
* fix: always refresh session (#95) | ||
1.11.2 / 2016-07-12 | ||
================== | ||
* fix: npm pack should not include test dir (#92) | ||
1.11.1 / 2016-06-23 | ||
@@ -3,0 +13,0 @@ ================== |
@@ -338,4 +338,19 @@ /**! | ||
yield next; | ||
yield refreshSession.call(this, this.session, result.originalHash, result.isNew); | ||
// make sure `refreshSession` always called | ||
var firstError = null; | ||
try { | ||
yield next; | ||
} catch (err) { | ||
debug('next logic error: %s', err.message); | ||
firstError = err; | ||
} | ||
// can't use finally because `refreshSession` is async | ||
try { | ||
yield refreshSession.call(this, this.session, result.originalHash, result.isNew); | ||
} catch (err) { | ||
debug('refresh session error: %s', err.message); | ||
if (firstError) this.app.emit('error', err, this); | ||
firstError = firstError || err; | ||
} | ||
if (firstError) throw firstError; | ||
} | ||
@@ -342,0 +357,0 @@ |
@@ -5,3 +5,7 @@ { | ||
"repository": "koajs/generic-session", | ||
"version": "1.11.1", | ||
"version": "1.11.3", | ||
"files": [ | ||
"lib", | ||
"index.js" | ||
], | ||
"keywords": [ | ||
@@ -15,6 +19,6 @@ "koa", | ||
"copy-to": "~2.0.1", | ||
"crc": "~3.3.0", | ||
"crc": "~3.4.0", | ||
"debug": "*", | ||
"parseurl": "~1.3.0", | ||
"uid-safe": "~2.1.0" | ||
"parseurl": "~1.3.1", | ||
"uid-safe": "~2.1.1" | ||
}, | ||
@@ -26,7 +30,8 @@ "devDependencies": { | ||
"istanbul-harmony": "*", | ||
"koa": "~1.1.2", | ||
"koa-redis": "~1.0.1", | ||
"mm": "~1.3.5", | ||
"koa": "~1.2.0", | ||
"koa-redis": "~2.1.1", | ||
"mm": "~1.5.0", | ||
"mocha": "2", | ||
"should": "~7.1.1", | ||
"pedding": "^1.0.0", | ||
"should": "~10.0.0", | ||
"supertest": "~0.13.0" | ||
@@ -33,0 +38,0 @@ }, |
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
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
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
2
1
29734
11
8
491
+ Addedcrc@3.4.4(transitive)
- Removedcrc@3.3.0(transitive)
Updatedcrc@~3.4.0
Updatedparseurl@~1.3.1
Updateduid-safe@~2.1.1