Add xhr in callbacks for page:fail, page:redirected, page:done.