Minor fixes to afk stuff.

This commit is contained in:
Xaekai 2017-06-29 19:04:49 -07:00
parent 7ebf3c18ab
commit 18bf1b946b
2 changed files with 2 additions and 2 deletions

View File

@ -419,7 +419,7 @@ Channel.prototype.acceptUser = function (user) {
} }
user.on('afk', function(afk){ user.on('afk', function(afk){
self.sendUserMeta(self.users, user, -1); self.sendUserMeta(self.users, user);
// TODO: Drop legacy setAFK frame after a few months // TODO: Drop legacy setAFK frame after a few months
self.broadcastAll("setAFK", { name: user.getName(), afk: afk }); self.broadcastAll("setAFK", { name: user.getName(), afk: afk });
}) })

View File

@ -520,7 +520,7 @@ Callbacks = {
* after script authors have had ample time to update * after script authors have had ample time to update
*/ */
socket.listeners('setAFK').forEach(function(listener){ socket.listeners('setAFK').forEach(function(listener){
listener(data.meta.afk); listener({ name: data.name, afk: data.meta.afk });
}); });
formatUserlistItem(user, data); formatUserlistItem(user, data);