give a user a brownie point when they start
This commit is contained in:
@ -51,6 +51,14 @@ module.exports = function(User) {
|
|||||||
user.email = typeof user.email === 'string' ?
|
user.email = typeof user.email === 'string' ?
|
||||||
user.email.trim().toLowerCase() :
|
user.email.trim().toLowerCase() :
|
||||||
user.email;
|
user.email;
|
||||||
|
|
||||||
|
if (!user.progressTimestamps) {
|
||||||
|
user.progressTimestamps = [];
|
||||||
|
}
|
||||||
|
|
||||||
|
if (user.progressTimestamps.length === 0) {
|
||||||
|
user.progressTimestamps.push({ timestamp: Date.now() });
|
||||||
|
}
|
||||||
}
|
}
|
||||||
next();
|
next();
|
||||||
});
|
});
|
||||||
|
@ -5,42 +5,38 @@ block content
|
|||||||
.panel.panel-info(ng-controller="profileValidationController")
|
.panel.panel-info(ng-controller="profileValidationController")
|
||||||
.panel-heading.text-center Manage your account here
|
.panel-heading.text-center Manage your account here
|
||||||
.panel-body
|
.panel-body
|
||||||
if (!user.isGithubCool)
|
.row
|
||||||
.row
|
|
||||||
.col-xs-12
|
.col-xs-12
|
||||||
a.btn.btn-lg.btn-block.btn-github.btn-link-social(href='/link/github')
|
if (!user.isGithubCool)
|
||||||
i.fa.fa-github
|
a.btn.btn-lg.btn-block.btn-github.btn-link-social(href='/auth/github')
|
||||||
| Link my GitHub to unlock this profile
|
i.fa.fa-github
|
||||||
else
|
| Link my GitHub to unlock this profile
|
||||||
.row
|
else
|
||||||
.col-xs-12
|
a.btn.btn-lg.btn-block.btn-github.btn-link-social(href='/link/github')
|
||||||
a.btn.btn-lg.btn-block.btn-github.btn-link-social(href='/link/github')
|
i.fa.fa-github
|
||||||
i.fa.fa-github
|
| Update my profile from Github
|
||||||
| Update my profile from Github
|
|
||||||
|
|
||||||
if (!user.twitter)
|
if (!user.twitter)
|
||||||
.col-xs-12
|
.col-xs-12
|
||||||
a.btn.btn-lg.btn-block.btn-twitter.btn-link-social(href='/link/twitter')
|
a.btn.btn-lg.btn-block.btn-twitter.btn-link-social(href='/link/twitter')
|
||||||
i.fa.fa-twitter
|
i.fa.fa-twitter
|
||||||
| Add my Twitter to my profile
|
| Add my Twitter to my profile
|
||||||
if (!user.facebook)
|
if (!user.facebook)
|
||||||
.col-xs-12
|
.col-xs-12
|
||||||
a.btn.btn-lg.btn-block.btn-facebook.btn-link-social(href='/link/facebook')
|
a.btn.btn-lg.btn-block.btn-facebook.btn-link-social(href='/link/facebook')
|
||||||
i.fa.fa-facebook
|
i.fa.fa-facebook
|
||||||
| Add my Facebook to my profile
|
| Add my Facebook to my profile
|
||||||
if (!user.linkedin)
|
if (!user.linkedin)
|
||||||
.col-xs-12
|
.col-xs-12
|
||||||
a.btn.btn-lg.btn-block.btn-linkedin.btn-link-social(href='/link/linkedin')
|
a.btn.btn-lg.btn-block.btn-linkedin.btn-link-social(href='/link/linkedin')
|
||||||
i.fa.fa-linkedin
|
i.fa.fa-linkedin
|
||||||
| Add my LinkedIn to my profile
|
| Add my LinkedIn to my profile
|
||||||
if (!user.google)
|
if (!user.google)
|
||||||
.col-xs-12
|
.col-xs-12
|
||||||
a.btn.btn-lg.btn-block.btn-google-plus.btn-link-social(href='/link/google')
|
a.btn.btn-lg.btn-block.btn-google-plus.btn-link-social(href='/link/google')
|
||||||
i.fa.fa-google-plus
|
i.fa.fa-google-plus
|
||||||
| Add my Google+ to my profile
|
| Add my Google+ to my profile
|
||||||
.spacer
|
.big-spacer
|
||||||
hr
|
|
||||||
.spacer
|
|
||||||
.col-xs-12
|
.col-xs-12
|
||||||
a.btn.btn-lg.btn-block.btn-warning.btn-link-social(href='/logout')
|
a.btn.btn-lg.btn-block.btn-warning.btn-link-social(href='/logout')
|
||||||
span.ion-android-exit
|
span.ion-android-exit
|
||||||
|
@ -99,7 +99,7 @@ block content
|
|||||||
| Click the "Wiki" button in your upper right hand corner. Our community has contributed lots of useful information to this searchable wiki.
|
| Click the "Wiki" button in your upper right hand corner. Our community has contributed lots of useful information to this searchable wiki.
|
||||||
|
|
||||||
.big-spacer
|
.big-spacer
|
||||||
img.gif-block.img-center.img-responsive.thumbnail(src='http://i.imgur.com/RlEk2IF.jpg' alt='a gif showing how to install this')
|
img.gif-block.img-center.img-responsive.thumbnail(src='https://www.evernote.com/l/AlwO6CNq-OJJXJ3qu2nu1E7ePe72hCSW5IcB/image.png' alt='a gif showing how to install this')
|
||||||
p.large-p.gif-caption
|
p.large-p.gif-caption
|
||||||
span.text-info Try this: 
|
span.text-info Try this: 
|
||||||
| Check out your portfolio page. Click your picture your upper right hand corner. Before you can see your portfolio page, you'll need to link your GitHub account with Free Code Camp.
|
| Check out your portfolio page. Click your picture your upper right hand corner. Before you can see your portfolio page, you'll need to link your GitHub account with Free Code Camp.
|
||||||
|
Reference in New Issue
Block a user