mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 08:36:12 +01:00
chore: remove deprecated User.emailConfirm [breaking]
Use `User.email.confirmByCode` instead.
This commit is contained in:
@@ -2,7 +2,6 @@
|
||||
'use strict';
|
||||
|
||||
const nconf = require('nconf');
|
||||
const winston = require('winston');
|
||||
|
||||
const user = require('./index');
|
||||
const utils = require('../utils');
|
||||
@@ -88,12 +87,6 @@ UserEmail.sendValidationEmail = async function (uid, options) {
|
||||
return confirm_code;
|
||||
};
|
||||
|
||||
UserEmail.confirm = async function (code) {
|
||||
// TODO: remove in 1.17.0
|
||||
winston.warn('[deprecated] User.email.confirm deprecated use User.email.confirmByCode');
|
||||
await UserEmail.confirmByCode(code);
|
||||
};
|
||||
|
||||
// confirm email by code sent by confirmation email
|
||||
UserEmail.confirmByCode = async function (code) {
|
||||
const confirmObj = await db.getObject('confirm:' + code);
|
||||
|
||||
Reference in New Issue
Block a user