notifications refactoring