<commit_before>'use strict';

const express = require('express');
const routes = require('./server/routes/index.js');
const mongoose = require('mongoose');
const passport = require('passport');
const session = require('express-session');
const bodyParser = require('body-parser');


const app = express();
require('dotenv').load();
require('./server/config/passport')(passport);

mongoose.connect(process.env.MONGODB_URI);
mongoose.Promise = global.Promise;

app.use(bodyParser.json());
app.use('/controllers', express.static(process.cwd() + '/server/controllers'));
app.use('/public', express.static(process.cwd() + '/public'));
app.use('/common', express.static(process.cwd() + '/server/common'));

app.use(session({
  secret: 'Vote or Die!',
  resave: false,
  saveUninitialized: true,
  // cookie: {secure: true},
}));

app.use(passport.initialize());
app.use(passport.session());
routes(app, passport);


const port = process.env.PORT || 8080;<commit_msg>fixing heroku issues<commit_after>'use strict';

const express = require('express');
const routes = require('./server/routes/index.js');
const mongoose = require('mongoose');
const passport = require('passport');
const session = require('express-session');
const bodyParser = require('body-parser');


const app = express();
// require('dotenv').load();
require('./server/config/passport')(passport);

mongoose.connect(process.env.MONGODB_URI);
mongoose.Promise = global.Promise;

app.use(bodyParser.json());
app.use('/controllers', express.static(process.cwd() + '/server/controllers'));
app.use('/public', express.static(process.cwd() + '/public'));
app.use('/common', express.static(process.cwd() + '/server/common'));

app.use(session({
  secret: 'Vote or Die!',
  resave: false,
  saveUninitialized: true,
  // cookie: {secure: true},
}));

app.use(passport.initialize());
app.use(passport.session());
routes(app, passport);


const port = process.env.PORT || 8080;
{'fraction_non_alphanumeric': 0.20103626943005182, 'fraction_numerical': 0.004145077720207254, 'mean_word_length': 6.047445255474453, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3765383', 'n_tokens_mistral': 614, 'n_tokens_neox': 612, 'n_words': 117}