session will be expire in 1 hour
This commit is contained in:
parent
35144b34c2
commit
7d755f033b
|
@ -23,6 +23,7 @@ module.exports = class Server {
|
|||
|
||||
constructor() {
|
||||
// Express
|
||||
const expiryDate = new Date(Date.now() + 60 * 60 * 1000); // 1 hour
|
||||
this.app = express()
|
||||
.disable('etag')
|
||||
.use('/', express.static(path.join(__dirname, '..', 'www')))
|
||||
|
@ -33,6 +34,7 @@ module.exports = class Server {
|
|||
saveUninitialized: true,
|
||||
cookie: {
|
||||
httpOnly: true,
|
||||
expires: expiryDate,
|
||||
},
|
||||
}))
|
||||
|
||||
|
|
Loading…
Reference in New Issue