code: function hasIndexChanged(index, prevIndex) {
    if (typeof index !== 'string' || !index) return false;
    if (typeof prevIndex !== 'string' || !prevIndex) return true;
    return index !== prevIndex;
  }
docs: Has the Consul index changed.