1
0
mirror of https://github.com/matrix-org/matrix-js-sdk.git synced 2025-11-28 05:03:59 +03:00

incorporate PR feedback

This commit is contained in:
Matthew Hodgson
2016-04-18 14:26:59 +01:00
parent 3af35c8209
commit 0e606c6fe2
2 changed files with 12 additions and 6 deletions

View File

@@ -143,6 +143,15 @@ User.prototype.getLastModifiedTime = function() {
return this._modified;
};
/**
* Get the absolute timestamp when this User was last known active on the server.
* It is *NOT* accurate if this.currentlyActive is true.
* @return {number} The timestamp
*/
User.prototype.getLastActiveTs = function() {
return this.lastPresenceTs - this.lastActiveAgo;
};
/**
* The User class.
*/