<commit_before>const express = require('express');
const {db} = require('./database/db-config');

const app = express();

// add middleware
require('./config/middleware.js')(app, express);

// add routes
require('./config/routes.js')(app, express);

// set port depending on prod or dev
const port = process.env.NODE_ENV === 'production' ? 80 : 3000;

const listen = app.listen(port, () => {
  console.log('Server listening on port ' + port);
  db.sync();
  // .then(() => {
  //   console.log('Database is synced');
  // });
});

var io = require('socket.io').listen(listen);

io.on('connection', (socket) => {
  console.log('a user connected');
  socket.on('disconnect', () => console.log('a user disconnected'));
});


module.exports = app;<commit_msg>(dev) force db.sync on server startup<commit_after>const express = require('express');
const {db} = require('./database/db-config');

const app = express();

// add middleware
require('./config/middleware.js')(app, express);

// add routes
require('./config/routes.js')(app, express);

// set port depending on prod or dev
const port = process.env.NODE_ENV === 'production' ? 80 : 3000;

const listen = app.listen(port, () => {
  console.log('Server listening on port ' + port);
  db.sync({force: true});
  // .then(() => {
  //   console.log('Database is synced');
  // });
});

var io = require('socket.io').listen(listen);

io.on('connection', (socket) => {
  console.log('a user connected');
  socket.on('disconnect', () => console.log('a user disconnected'));
});


module.exports = app;
{'fraction_non_alphanumeric': 0.2094376212023271, 'fraction_numerical': 0.007756948933419522, 'mean_word_length': 4.0588235294117645, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 11, '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': '1599585', 'n_tokens_mistral': 497, 'n_tokens_neox': 481, 'n_words': 119}