Commit bbc419e9 authored by Vladimir Baranov's avatar Vladimir Baranov

rref #5392. Reinit messaging when user logged in

parent 252ad1a6
......@@ -293,6 +293,15 @@ angular.module("ulakbus.messaging")
$rootScope.$on("notifications", function(e, notification){
appendMessage(iScope.selectedChannel, MessagingService.prepareMessage(notification));
});
$rootScope.$on("user_ready", function(){
// init service after user logged in
iScope.selectedChannel = null;
iScope.publicChannels = [];
iScope.notificationsChannel = [];
iScope.directChannels = []
iScope.hideApp();
});
}
};
})
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment