Merge pull request #373 from wilsonge/patch-1

Fix doc blocks
This commit is contained in:
Mor Shemesh 2018-04-16 14:01:44 +03:00 коммит произвёл GitHub
Родитель 8c55afe1a9 99e6e0a9ff
Коммит acabc27a33
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
1 изменённых файлов: 8 добавлений и 8 удалений

Просмотреть файл

@ -167,9 +167,9 @@ function addAuthRoutes() {
// GET /auth/openid/return // GET /auth/openid/return
// Use passport.authenticate() as route middleware to authenticate the // Use passport.authenticate() as route middleware to authenticate the
// request. If authentication fails, the user will be redirected back to the // request. If authentication fails, the user will be redirected back to the
// login page. Otherwise, the primary route function function will be called, // sign-in page. Otherwise, the primary route function will be called.
// which, in this example, will redirect the user to the home page. // In this example, it redirects the user to the home page.
router.get('/openid/return', router.get('/openid/return',
passport.authenticate('azuread-openidconnect', { failureRedirect: '/auth/login' }), passport.authenticate('azuread-openidconnect', { failureRedirect: '/auth/login' }),
function(req, res) { function(req, res) {
@ -178,11 +178,11 @@ function addAuthRoutes() {
redirectPath = null; redirectPath = null;
}); });
// GET /auth/openid/return // POST /auth/openid/return
// Use passport.authenticate() as route middleware to authenticate the // Use passport.authenticate() as route middleware to authenticate the
// request. If authentication fails, the user will be redirected back to the // request. If authentication fails, the user will be redirected back to the
// login page. Otherwise, the primary route function function will be called, // sign-in page. Otherwise, the primary route function will be called.
// which, in this example, will redirect the user to the home page. // In this example, it will redirect the user to the home page.
router.post('/openid/return', router.post('/openid/return',
passport.authenticate('azuread-openidconnect', { failureRedirect: '/auth/login' }), passport.authenticate('azuread-openidconnect', { failureRedirect: '/auth/login' }),
function(req, res) { function(req, res) {
@ -278,4 +278,4 @@ module.exports = {
// Returning a middleware array // Returning a middleware array
authenticationMiddleware, authenticationMiddleware,
router router
} }