import { getStakings } from '@rss3/api-core';
import { useQuery } from '@tanstack/react-query';

function useGetStakings(params, options) {
  const queryKey = ["useGetStakings", params];
  const query = useQuery({
    queryKey,
    queryFn: () => {
      const args = Array.isArray(params) ? params : [params];
      return getStakings(...args);
    },
    ...options
  });
  return {
    ...query,
    queryKey
  };
}

export { useGetStakings };
//# sourceMappingURL=use-get-stakings.js.map
//# sourceMappingURL=use-get-stakings.js.map