Refactor and break down sending notifications.