Fixing some bugs with notifications.