mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-02 03:55:55 +01:00
new translation strings for pages, proper unicode handling in parseFragment
This commit is contained in:
11
src/user.js
11
src/user.js
@@ -733,6 +733,17 @@ var bcrypt = require('bcryptjs'),
|
||||
});
|
||||
};
|
||||
|
||||
User.getUsernameByUserslug = function(slug, callback) {
|
||||
async.waterfall([
|
||||
function(next) {
|
||||
User.getUidByUserslug(slug, next);
|
||||
},
|
||||
function(uid, next) {
|
||||
User.getUserField(uid, 'username', next);
|
||||
}
|
||||
], callback);
|
||||
};
|
||||
|
||||
User.getUidByEmail = function(email, callback) {
|
||||
db.getObjectField('email:uid', email, function(err, data) {
|
||||
if (err) {
|
||||
|
||||
Reference in New Issue
Block a user