[Notifications][Kashish] refactoring notifications.js