summary refs log tree commit diff
path: root/webclient/recents
diff options
context:
space:
mode:
authorEmmanuel ROHEE <erohee@amdocs.com>2014-09-12 17:43:25 +0200
committerEmmanuel ROHEE <erohee@amdocs.com>2014-09-12 17:43:35 +0200
commit3ed39ad20e20556ce8f103d2187a5699ceac95f9 (patch)
treeec22792c12d9395046abc90da57e73dd9165e918 /webclient/recents
parentRetry sending events that fail to send. (diff)
downloadsynapse-3ed39ad20e20556ce8f103d2187a5699ceac95f9.tar.xz
Clean data when user logs out
Diffstat (limited to 'webclient/recents')
-rw-r--r--webclient/recents/recents-controller.js9
1 files changed, 7 insertions, 2 deletions
diff --git a/webclient/recents/recents-controller.js b/webclient/recents/recents-controller.js
index b65f97439f..a0db0538f3 100644
--- a/webclient/recents/recents-controller.js
+++ b/webclient/recents/recents-controller.js
@@ -102,7 +102,7 @@ angular.module('RecentsController', ['matrixService', 'matrixFilter', 'eventHand
         }
         
         return memberCount;
-    }
+    };
 
     $scope.onInit = function() {
         // Init recents list only once
@@ -139,6 +139,11 @@ angular.module('RecentsController', ['matrixService', 'matrixFilter', 'eventHand
             }
         );
     };
-    
+
+    // Clean data when user logs out
+    $scope.$on(eventHandlerService.RESET_EVENT, function() {
+
+        delete $rootScope.rooms;
+    });
 }]);