فهرست منبع

allow password resets to be performed when site is not public by adding routes into white list

Henry Oswald 11 سال پیش
والد
کامیت
312c56a24e
1فایلهای تغییر یافته به همراه3 افزوده شده و 0 حذف شده
  1. 3 0
      services/web/app/coffee/Features/PasswordReset/PasswordResetRouter.coffee

+ 3 - 0
services/web/app/coffee/Features/PasswordReset/PasswordResetRouter.coffee

@@ -1,11 +1,14 @@
 PasswordResetController = require("./PasswordResetController")
 PasswordResetController = require("./PasswordResetController")
+AuthenticationController = require('../Authentication/AuthenticationController')
 
 
 module.exports =
 module.exports =
 	apply: (app) ->
 	apply: (app) ->
 
 
 		app.get  '/user/password/reset', PasswordResetController.renderRequestResetForm
 		app.get  '/user/password/reset', PasswordResetController.renderRequestResetForm
 		app.post  '/user/password/reset', PasswordResetController.requestReset
 		app.post  '/user/password/reset', PasswordResetController.requestReset
+		AuthenticationController.addEndpointToLoginWhitelist '/user/password/reset'
 		
 		
 		app.get '/user/password/set', PasswordResetController.renderSetPasswordForm
 		app.get '/user/password/set', PasswordResetController.renderSetPasswordForm
 		app.post '/user/password/set', PasswordResetController.setNewUserPassword
 		app.post '/user/password/set', PasswordResetController.setNewUserPassword
+		AuthenticationController.addEndpointToLoginWhitelist '/user/password/set'