Skip to content

Commit 2878104

Browse files
rihadavidflovilmart
authored andcommitted
Include username in password reset email (#3969)
When user resets his password, he does it by filling his email. But often he could also not remember his username, which he needs for logging in. I think it's better to include the username in the password reset email, what do you think?
1 parent 457e21d commit 2878104

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/Controllers/UserController.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,8 @@ export class UserController extends AdaptableController {
213213

214214
defaultResetPasswordEmail({link, user, appName, }) {
215215
const text = "Hi,\n\n" +
216-
"You requested to reset your password for " + appName + ".\n\n" +
216+
"You requested to reset your password for " + appName +
217+
(user.get('username') ? (" (your username is '" + user.get('username') + "')") : "") + ".\n\n" +
217218
"" +
218219
"Click here to reset it:\n" + link;
219220
const to = user.get("email") || user.get('username');

0 commit comments

Comments
 (0)