[polari/wip/fmuellner/combined-gsoc: 129/136] userTracker: Minor cleanup
- From: Florian Müllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [polari/wip/fmuellner/combined-gsoc: 129/136] userTracker: Minor cleanup
- Date: Tue, 26 Jul 2016 23:26:49 +0000 (UTC)
commit 1d5a645846451ff62193fcd1a6265c1ec7193693
Author: Florian Müllner <fmuellner gnome org>
Date: Tue Jul 26 23:33:12 2016 +0200
userTracker: Minor cleanup
When a room is removed, rather than duplicating the condition for
whether the room is tracked, we can just check whether we have
room data for it - everything the function does will be useless
anyway if we don't have any data to operate on ...
src/userTracker.js | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/userTracker.js b/src/userTracker.js
index 412adac..85703be 100644
--- a/src/userTracker.js
+++ b/src/userTracker.js
@@ -117,7 +117,7 @@ const UserTracker = new Lang.Class({
},
_onRoomRemoved: function(roomManager, room) {
- if (room.account != this._account)
+ if (!this._roomData.has(room))
return;
this._getRoomSignals(room).forEach(id => { room.disconnect(id); });
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]