refactored notifications to send 2 types of notif.