<commit_before>var config = require('../config/config.json');

var User = require('../models/User');

// API PROVIDERS SETUP
var foursquare = require('node-foursquare')({
  secrets: {
    clientId: config.foursquare.clientId,
    clientSecret: config.foursquare.clientSecret,
    redirectUrl: config.foursquare.callbackUrl
  }
});

var foursquareAccessToken = 'MY_FOURSQUARE_ACCESS_TOKEN';


exports.apiBrowser = function(req, res) {
  res.render('api', {
    title: 'API Browser'
  });
};


exports.foursquare = function(req, res) {

  res.render('api/foursquare', {
    title: 'Foursquare API'
  });

};


/**<commit_msg>Pass user to api and foursquare api pages<commit_after>var config = require('../config/config.json');

var User = require('../models/User');

// API PROVIDERS SETUP
var foursquare = require('node-foursquare')({
  secrets: {
    clientId: config.foursquare.clientId,
    clientSecret: config.foursquare.clientSecret,
    redirectUrl: config.foursquare.callbackUrl
  }
});

var foursquareAccessToken = 'MY_FOURSQUARE_ACCESS_TOKEN';


exports.apiBrowser = function(req, res) {
  res.render('api', {
    title: 'API Browser',
    user: req.user
  });
};


exports.foursquare = function(req, res) {

  res.render('api/foursquare', {
    title: 'Foursquare API',
    user: req.user
  });

};


/**
{'fraction_non_alphanumeric': 0.1552511415525114, 'fraction_numerical': 0.0, 'mean_word_length': 3.981060606060606, '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': '4357084', 'n_tokens_mistral': 456, 'n_tokens_neox': 446, 'n_words': 83}