* Rework user.js and User object to ES6

* Update download stats for user when web download is completed
This commit is contained in:
Bryan Ashby 2017-02-18 13:21:18 -07:00
parent 6406d32165
commit 058ff3f367
14 changed files with 569 additions and 516 deletions

View file

@ -9,7 +9,7 @@ const theme = require('./theme.js');
const Message = require('./message.js');
const updateMessageAreaLastReadId = require('./message_area.js').updateMessageAreaLastReadId;
const getMessageAreaByTag = require('./message_area.js').getMessageAreaByTag;
const getUserIdAndName = require('./user.js').getUserIdAndName;
const User = require('./user.js');
const cleanControlCodes = require('./string_util.js').cleanControlCodes;
const StatLog = require('./stat_log.js');
const stringFormat = require('./string_format.js');
@ -373,7 +373,7 @@ exports.FullScreenEditorModule = exports.getModule = class FullScreenEditorModul
callback(null);
} else {
// we need to look it up
getUserIdAndName(self.message.toUserName, function userInfo(err, toUserId) {
User.getUserIdAndName(self.message.toUserName, function userInfo(err, toUserId) {
if(err) {
callback(err);
} else {