<commit_before>'use strict';

const mongoose = require('mongoose');
const config = require('../config');

module.exports = function () {
  mongoose.connect(config.mongoDB.uri, config.mongoDB.options);
  mongoose.connection.on('error', (err) => {
    console.error(`MongoDB connection error: ${err}`);
  });
};
<commit_msg>Set promise<commit_after>'use strict';

const mongoose = require('mongoose');
const config = require('../config');
mongoose.Promise = global.Promise;

module.exports = function () {
  mongoose.connect(config.mongoDB.uri, config.mongoDB.options);
  mongoose.connection.on('error', (err) => {
    console.error(`MongoDB connection error: ${err}`);
  });
};

{'fraction_non_alphanumeric': 0.1861152141802068, 'fraction_numerical': 0.0, 'mean_word_length': 5.220183486238532, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, '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': '2987847', 'n_tokens_mistral': 214, 'n_tokens_neox': 224, 'n_words': 39}