Better naming
This commit is contained in:
@ -76,7 +76,7 @@ async function addHttpRoutes(app: Application) {
|
||||
}
|
||||
|
||||
const userService = new UserService()
|
||||
const sentEmail = await userService.resetPassword(email)
|
||||
const sentEmail = await userService.requestPasswordReset(email)
|
||||
|
||||
if (sentEmail) {
|
||||
return res.status(200).json({ message: 'Email has been sent' })
|
||||
@ -100,7 +100,7 @@ async function addHttpRoutes(app: Application) {
|
||||
}
|
||||
|
||||
const userService = new UserService()
|
||||
const resetPassword = await userService.newPassword(urlToken, password)
|
||||
const resetPassword = await userService.resetPassword(urlToken, password)
|
||||
|
||||
if (resetPassword) {
|
||||
return res.status(200).json({ message: 'Password has been reset' })
|
||||
|
Reference in New Issue
Block a user