Add display on user profile when user commits
This commit is contained in:
@@ -164,7 +164,10 @@ module.exports = function(app) {
|
||||
const username = req.params.username.toLowerCase();
|
||||
const { path } = req;
|
||||
User.findOne(
|
||||
{ where: { username } },
|
||||
{
|
||||
where: { username },
|
||||
include: 'pledge'
|
||||
},
|
||||
function(err, profileUser) {
|
||||
if (err) {
|
||||
return next(err);
|
||||
@@ -175,6 +178,7 @@ module.exports = function(app) {
|
||||
});
|
||||
return res.redirect('/');
|
||||
}
|
||||
profileUser = profileUser.toJSON();
|
||||
|
||||
var cals = profileUser
|
||||
.progressTimestamps
|
||||
@@ -217,7 +221,6 @@ module.exports = function(app) {
|
||||
return (obj.name || '').match(/^Waypoint/i);
|
||||
});
|
||||
|
||||
debug('user is fec', profileUser.isFrontEndCert);
|
||||
res.render('account/show', {
|
||||
title: 'Camper ' + profileUser.username + '\'s portfolio',
|
||||
username: profileUser.username,
|
||||
@@ -227,6 +230,8 @@ module.exports = function(app) {
|
||||
isGithubCool: profileUser.isGithubCool,
|
||||
isLocked: !!profileUser.isLocked,
|
||||
|
||||
pledge: profileUser.pledge,
|
||||
|
||||
isFrontEndCert: profileUser.isFrontEndCert,
|
||||
isFullStackCert: profileUser.isFullStackCert,
|
||||
isHonest: profileUser.isHonest,
|
||||
|
Reference in New Issue
Block a user