🎉 update format
This commit is contained in:
+1
-1
@@ -1,2 +1,2 @@
|
||||
PORT=3000
|
||||
HREF="https://your.domain.com/"
|
||||
HREF="https://your.domain.com/"
|
||||
+1
-1
@@ -6,4 +6,4 @@ data.db-journal
|
||||
*.db
|
||||
package-lock.json
|
||||
yarn.lock
|
||||
*.*~
|
||||
*.*~
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
require('dotenv').config()
|
||||
require('dotenv').config();
|
||||
const express = require('express');
|
||||
const path = require('path');
|
||||
const session = require('express-session');
|
||||
@@ -38,14 +38,14 @@ app.set('trust proxy', true);
|
||||
app.use(
|
||||
rateLimit({
|
||||
windowMs: 30 * 1000,
|
||||
max: 30,
|
||||
max: 30
|
||||
})
|
||||
);
|
||||
app.use(
|
||||
'/login',
|
||||
rateLimit({
|
||||
windowMs: 60 * 1000,
|
||||
max: 5,
|
||||
max: 5
|
||||
})
|
||||
);
|
||||
app.use(compression());
|
||||
@@ -57,7 +57,7 @@ app.use(
|
||||
session({
|
||||
resave: true,
|
||||
saveUninitialized: true,
|
||||
secret: config.session_secret,
|
||||
secret: config.session_secret
|
||||
})
|
||||
);
|
||||
app.use(flash());
|
||||
@@ -65,7 +65,7 @@ app.use(express.static(path.join(__dirname, 'public')));
|
||||
app.use(
|
||||
'/public',
|
||||
serveStatic(path.join(__dirname, `public`), {
|
||||
maxAge: '600000',
|
||||
maxAge: '600000'
|
||||
})
|
||||
);
|
||||
app.use('*', (req, res, next) => {
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "message-pusher",
|
||||
"version": "0.2.0",
|
||||
"version": "0.2.2",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"start": "node ./app.js",
|
||||
|
||||
Reference in New Issue
Block a user