{"size": 406, "ext": "js", "max_stars_repo_path": "server/controllers/index.server.controller.js", "max_stars_repo_name": "xudaosong/myMoney", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "server/controllers/index.server.controller.js", "max_issues_repo_name": "xudaosong/myMoney", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "server/controllers/index.server.controller.js", "max_forks_repo_name": "xudaosong/myMoney", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 23.8823529412, "max_line_length": 52, "alphanum_fraction": 0.539408867}
exports.render = function (req, res) {
    // if (req.session.lastVisit) {
    //     console.log(req.session.lastVisit);
    // }
    // req.session.lastVisit = new Date();

    res.render('index', {
        user: JSON.stringify(req.user)
    });

};
exports.requiresLogin = function (req, res, next) {
    if (!req.isAuthenticated()) {
        res.redirect('/login');
    }
    next();
};