mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-01-01 13:20:41 +01:00
fix: only show emailChanged alert for self
This commit is contained in:
@@ -97,7 +97,9 @@ Interstitials.email = async (data) => {
|
||||
}).catch((err) => {
|
||||
winston.error(`[user.interstitials.email] Validation email failed to send\n[emailer.send] ${err.stack}`);
|
||||
});
|
||||
data.req.session.emailChanged = 1;
|
||||
if (isSelf) {
|
||||
data.req.session.emailChanged = 1;
|
||||
}
|
||||
} else {
|
||||
// User attempting to edit another user's email -- not allowed
|
||||
throw new Error('[[error:no-privileges]]');
|
||||
|
||||
Reference in New Issue
Block a user