Fix 500 error on notifications.