<commit_before>(function(module) {
  var homeController = {};

  homeController.index = function() {
    $('#home').show().siblings().hide();
    $('#login-signup').hide();

    // pg.connect(process.env.DATABASE_URL, function(err, client) {
    //   if (err) throw err;
    //   console.log('Connected to postgres! Getting schemas...');
    //
    //   client
    //     .query('SELECT * FROM users;')
    //     .on('row', function(row) {
    //       console.log(JSON.stringify(row));
    //     });
    // });

  };

  homeController.fetchAll = function(){
    $.getJSON('/data', function (result) {
      console.log('Scott was here');
      console.log(result);
      console.log(result.row);

      // result.rows.forEach(function(item) {
      //   if (item.list){
      //     console.log('if state');
      //     item.list = JSON.parse(item.list);
      //   }
      //   console.log('else');
      // });
    });
  };
  homeController.fetchAll();

  module.homeController = homeController;
})(window);
<commit_msg>more server<commit_after>(function(module) {
  var homeController = {};

  homeController.index = function() {
    $('#home').show().siblings().hide();
    $('#login-signup').hide();
  };

  homeController.fetchAll = function(){
    $.getJSON('/data', function (result) {
      console.log('Scott was here');
      // console.log(result);
      // console.log(result.row);

      result.rows.forEach(function(item) {
        console.log(item);
      //   if (item.list){
      //     console.log('if state');
      //     item.list = JSON.parse(item.list);
      //   }
      //   console.log('else');
      });
    });
  };
  homeController.fetchAll();

  module.homeController = homeController;
})(window);

{'fraction_non_alphanumeric': 0.20288184438040346, 'fraction_numerical': 0.0, 'mean_word_length': 2.244859813084112, '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': '5194755', 'n_tokens_mistral': 548, 'n_tokens_neox': 537, 'n_words': 79}