<commit_before>var artistController = require('../controllers/artist-controller');
var genreController = require('../controllers/genre-controller');

module.exports = function(app, passport) {
  app.get('/auth/facebook', passport.authenticate('facebook', { scope : 'email' }));

  app.get('/auth/facebook/callback',
  passport.authenticate('facebook', {
    failureRedirect : '/',
    successRedirect : '/'
  }));

  app.get('/profile', function(req, res) {
    return res.send(200);
  });

  app.post('/api/artist/:id/like', artistController.likeArtist);
  app.get('/api/artist/recommendation', artistController.getArtistRecommendations);

  app.get('/api/genre', genreController.getGenres);
  app.get('/api/genre/artists', genreController.getArtistsByGenre);

  app.get('*', function(req, res) {<commit_msg>Change permissions and add ability to make jobs<commit_after>var artistController = require('../controllers/artist-controller');
var genreController = require('../controllers/genre-controller');
var queue = require('../workers/queue');

module.exports = function(app, passport) {
  app.get('/auth/facebook', passport.authenticate('facebook', { scope : ['email', 'user_likes'] }));

  app.get('/auth/facebook/callback',
  passport.authenticate('facebook', {
    failureRedirect : '/'
  }),
  function(req, res) {
    queue.crawlUser(req.user.dataValues);
    res.redirect('/');
  });

  app.get('/profile', function(req, res) {
    return res.send(200);
  });

  app.post('/api/artist/:id/like', artistController.likeArtist);
  app.get('/api/artist/recommendation', artistController.getArtistRecommendations);

  app.get('/api/genre', genreController.getGenres);
  app.get('/api/genre/artists', genreController.getArtistsByGenre);

  app.get('*', function(req, res) {
{'fraction_non_alphanumeric': 0.18535211267605634, 'fraction_numerical': 0.0033802816901408453, 'mean_word_length': 4.92, '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': '868041', 'n_tokens_mistral': 573, 'n_tokens_neox': 550, 'n_words': 80}