<commit_before>var express      = require('express')
var cookieParser = require('cookie-parser')
var bodyParser   = require('body-parser')
var routes       = require('./routes/directors.js')
var app          = express()

app.use(bodyParser.urlencoded({ extended: true }))
app.use(bodyParser.json())
app.use(cookieParser())


app.use('/', routes)

module.exports = app<commit_msg>add redis connection to app<commit_after>var express      = require('express')
var cookieParser = require('cookie-parser')
var bodyParser   = require('body-parser')
var routes       = require('./routes/directors.js')
var app          = express()

var Director = require('./models/director')
var nohm  = require('nohm').Nohm;
var redis = require('redis').createClient();

app.use(bodyParser.urlencoded({ extended: true }))
app.use(bodyParser.json())
app.use(cookieParser())

nohm.setClient(redis)
app.use(nohm.connect([{
  model: Director
}]))

app.use('/', routes)

module.exports = app
{'fraction_non_alphanumeric': 0.16580310880829016, 'fraction_numerical': 0.0, 'mean_word_length': 4.551724137931035, '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': '990057', 'n_tokens_mistral': 302, 'n_tokens_neox': 301, 'n_words': 64}