mirror of
https://github.com/danbulant/discord.js
synced 2026-05-25 04:52:22 +00:00
Added user presence tracking changes
User status in cache is now updated as well as firing the event
This commit is contained in:
parent
ca1b4bdf0e
commit
76e9cef7e1
2 changed files with 2 additions and 0 deletions
|
|
@ -1087,6 +1087,7 @@ var Client = (function () {
|
|||
var presenceUser = new User(data.user);
|
||||
if (presenceUser.equalsStrict(userInCache)) {
|
||||
//they're exactly the same, an actual presence update
|
||||
userInCache.status = data.status;
|
||||
self.trigger("presence", {
|
||||
user: userInCache,
|
||||
status: data.status,
|
||||
|
|
|
|||
|
|
@ -992,6 +992,7 @@ class Client {
|
|||
var presenceUser = new User(data.user);
|
||||
if (presenceUser.equalsStrict(userInCache)) {
|
||||
//they're exactly the same, an actual presence update
|
||||
userInCache.status = data.status;
|
||||
self.trigger("presence", {
|
||||
user: userInCache,
|
||||
status: data.status,
|
||||
|
|
|
|||
Loading…
Reference in a new issue