Skip to content
This repository was archived by the owner on Apr 13, 2023. It is now read-only.

Commit aebf6ef

Browse files
committed
clean up a few things
1 parent ceb5739 commit aebf6ef

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

app/helpers/database.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,16 @@ var mongoose = require('mongoose'),
55
routes = require('../routes'),
66
flash = require('connect-flash'),
77
session = require('express-session'),
8-
log = require('./logger');
9-
MongoDBStore = require('connect-mongodb-session')(session);
8+
log = require('./logger'),
9+
MongoDBStore = require('connect-mongodb-session')(session);
1010

11-
notForApi = function (fn) {
11+
const notForApi = function (callback) {
1212
return function(req, res, next) {
13-
if (req.path.indexOf('/api') === 0) {
14-
next();
15-
} else {
16-
fn(req, res, next);
17-
}
13+
if (req.path.indexOf('/api') === 0) {
14+
next();
15+
} else {
16+
callback(req, res, next);
17+
}
1818
}
1919
}
2020

0 commit comments

Comments
 (0)