diff options
author | LarsVomMars | 2020-10-01 17:51:06 +0200 |
---|---|---|
committer | LarsVomMars | 2020-10-01 17:51:06 +0200 |
commit | ce4f9770702ee261b238a3466b1e1cf27246dfc8 (patch) | |
tree | a3b361003a5f0bd0a5670b7a6a3959380aa507fa /app.js | |
parent | 590723afb4178e070a372d6e6054fe4d8549a4b0 (diff) |
Login, sessions, password reset
Diffstat (limited to 'app.js')
-rw-r--r-- | app.js | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -1,5 +1,6 @@ require("dotenv").config(); const express = require("express"); +const session = require("express-session"); const motto = require("./motto"); const auth = require("./auth"); @@ -7,6 +8,8 @@ const quotes = require("./quotes"); const app = express(); +app.use(session({ secret: "keyboard cat", resave: false, saveUninitialized: true, cookie: { secure: true } })); + app.use(express.urlencoded({ extended: true })); app.use(express.json()); |