Refactor notifications (again).