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

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

export { useGetNodeRewards };
//# sourceMappingURL=use-get-node-rewards.js.map
//# sourceMappingURL=use-get-node-rewards.js.map