import { useFetch as s } from "../../../../hooks/useFetch.js";
import { useConfigContext as a } from "../../../../core/ConfigContext/preact/context.js";
import { EMPTY_OBJECT as p } from "../../../../utils/value/constants.js";
const f = (o, t, n, r) => {
  const e = a().endpoints[o];
  return s({
    fetchOptions: { enabled: !!e && n, keepPrevData: !0, onSuccess: r },
    queryFn: async () => e(p, { ...t })
  });
};
export {
  f as default
};
