Skip to content

Commit

Permalink
Fix user updating password after x amount of time
Browse files Browse the repository at this point in the history
  • Loading branch information
pacifiquemboni committed Jul 22, 2024
1 parent 8ab5c1a commit aa50350
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
5 changes: 4 additions & 1 deletion src/helps/MailTemplate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@ const millisecondsToDate = require('./datesConversion');
import dotenv from 'dotenv';
dotenv.config();

export const sendChangePasswordNotificationMail = (userToken: any, userName: string) => `
export const sendChangePasswordNotificationMail = (
userToken: any,
userName: string,
) => `
<!DOCTYPE html>
<html lang="en">
<head>
Expand Down
5 changes: 4 additions & 1 deletion src/utils/sendChangePasswordNofication.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,10 @@ function changePasswordUpdateNotification(user: any, token: string): void {
const userName: string = user.firstName;
const userToken: string = token;
const subject: string = 'You are required to update your password';
const htmlContent: string = sendChangePasswordNotificationMail(userToken,userName);
const htmlContent: string = sendChangePasswordNotificationMail(
userToken,
userName,
);
sendMail(email, userName, subject, htmlContent);
}

Expand Down

0 comments on commit aa50350

Please sign in to comment.