<commit_before>var log     = require('../log')(module);
var User    = require('../models').User;

var profile = function(req, res) {    
    var user = req.user;
    // req.authInfo is set using the `info` argument supplied by `BearerStrategy`.
    // It is typically used to indicate scope of the token, and used in access control checks. 
    console.log(user);
    res.send({ 
            user: {
                userId: user.userId,
                username: user.username,
                firstName: user.firstName,
                lastName: user.lastName,
                imageUrl: user.imageUrl
            },
            scope: req.authInfo.scope 
        });
};

var getAllUsers = function(req, res) {
    return User.find(function (err, users) {
        if (!err) {
            return res.send({ users: users});
        } else {
            res.statusCode = 500;<commit_msg>changed userproifle<commit_after>var log     = require('../log')(module);
var User    = require('../models').User;

var profile = function(req, res) {    
    var user = req.user;
    // req.authInfo is set using the `info` argument supplied by `BearerStrategy`.
    // It is typically used to indicate scope of the token, and used in access control checks. 
    // e.g. req.authInfo.scope 
    console.log(user);
    res.send({ 
        userId: user.userId,
        username: user.username,
        firstName: user.firstName,
        lastName: user.lastName,
        imageUrl: user.imageUrl
    });
};

var getAllUsers = function(req, res) {
    return User.find(function (err, users) {
        if (!err) {
            return res.send({ users: users});
        } else {
            res.statusCode = 500;
{'fraction_non_alphanumeric': 0.1226303317535545, 'fraction_numerical': 0.0035545023696682463, 'mean_word_length': 1.9840989399293287, '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': '6872177', 'n_tokens_mistral': 497, 'n_tokens_neox': 479, 'n_words': 141}