Refactor notifications to use a cleaner interface