merge method

ZenQueryConfig<T> merge(
  1. ZenQueryConfig<T>? other
)

Merge with another config

Implementation

ZenQueryConfig<T> merge(ZenQueryConfig<T>? other) {
  if (other == null) return this;

  return ZenQueryConfig<T>(
    staleTime: other.staleTime ?? staleTime,
    cacheTime: other.cacheTime ?? cacheTime,
    refetchOnMount: other.refetchOnMount,
    refetchOnFocus: other.refetchOnFocus,
    refetchOnReconnect: other.refetchOnReconnect,
    refetchInterval: other.refetchInterval ?? refetchInterval,
    enableBackgroundRefetch: other.enableBackgroundRefetch,
    retryCount: other.retryCount,
    retryDelay: other.retryDelay,
    exponentialBackoff: other.exponentialBackoff,
    persist: other.persist,
    fromJson: other.fromJson ?? fromJson,
    toJson: other.toJson ?? toJson,
    storage: other.storage ?? storage,
    placeholderData: other.placeholderData ?? placeholderData,
  );
}