File tree Expand file tree Collapse file tree 3 files changed +5
-6
lines changed
Expand file tree Collapse file tree 3 files changed +5
-6
lines changed Original file line number Diff line number Diff line change 11{
22 "name" : " koa-session-minimal" ,
3- "version" : " 3.0.2 " ,
3+ "version" : " 3.0.3 " ,
44 "description" : " Minimal implementation of session middleware for Koa 2. Inspired by and compatible with koa-generic-session" ,
55 "main" : " dist/session.js" ,
66 "scripts" : {
3939 "babel-register" : " ^6.14.0" ,
4040 "chai" : " ^3.5.0" ,
4141 "eslint" : " ^3.4.0" ,
42- "eslint-config-airbnb-base" : " ^8 .0.0" ,
43- "eslint-plugin-import" : " ^1.16 .0" ,
42+ "eslint-config-airbnb-base" : " ^11 .0.0" ,
43+ "eslint-plugin-import" : " ^2.2 .0" ,
4444 "istanbul" : " ^0.4.5" ,
4545 "koa" : " ^2.0.0-alpha.7" ,
4646 "koa-generic-session-mongo" : " ^0.3.0" ,
Original file line number Diff line number Diff line change @@ -9,7 +9,6 @@ const cookieOpt = (cookie) => {
99 const options = Object . assign ( {
1010 maxAge : 0 , // default to use session cookie
1111 path : '/' ,
12- secure : false ,
1312 httpOnly : true ,
1413 } , cookie || { } , {
1514 overwrite : true , // overwrite previous session cookie changes
@@ -39,7 +38,7 @@ module.exports = (options) => {
3938 const store = new Store ( opt . store || new MemoryStore ( ) )
4039 const cookie = opt . cookie instanceof Function ? opt . cookie : cookieOpt ( opt . cookie )
4140
42- return async ( ctx , next ) => { // eslint-disable-line arrow-parens
41+ return async ( ctx , next ) => {
4342 // initialize session id and data
4443 const cookieSid = ctx . cookies . get ( key )
4544
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ class AsyncStore {
2727 }
2828
2929 async get ( sid ) {
30- return await this . store . get ( sid )
30+ return this . store . get ( sid )
3131 }
3232
3333 async set ( sid , val , ttl ) {
You can’t perform that action at this time.
0 commit comments