From 221a14315b09946db2485036bbf4a80295dc4889 Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Wed, 2 Jul 2014 16:22:51 -0400 Subject: password reset / username dupe stuff from PH --- server/index.js | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'server/index.js') diff --git a/server/index.js b/server/index.js index b008131..bb242ee 100644 --- a/server/index.js +++ b/server/index.js @@ -61,6 +61,7 @@ site.setup = function(){ app.use(passport.initialize()); app.use(passport.session()); app.use(app.router); + app.enable('trust proxy') app.get('env') === 'development' && app.use(express.errorHandler()); // Essential middleware @@ -90,6 +91,13 @@ site.route = function () { app.get('/auth/twitter/callback', auth.loggedIn('twitter')); app.get('/auth/facebook', auth.login('facebook')); app.get('/auth/facebook/callback', auth.loggedIn('facebook')); + app.get('/auth/usernameTaken', auth.views.usernameTaken); + app.post('/auth/usernameTaken', auth.usernameFixed); + app.get('/auth/password', auth.views.resetPassword); + app.post('/auth/password', auth.resetPassword); + app.post('/auth/passwordForgot', auth.forgotPassword); + + app.get('/profile', views.profile) app.get('/profile/edit', views.profile) app.get('/profile/:name', views.profile) -- cgit v1.2.3-70-g09d2