added the notification loop