@zoralabs/protocol-deployments 0.5.6-PRE.4 → 0.5.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zoralabs/protocol-deployments",
3
- "version": "0.5.6-PRE.4",
3
+ "version": "0.5.7",
4
4
  "repository": "https://github.com/ourzora/zora-protocol",
5
5
  "license": "MIT",
6
6
  "type": "module",
package/src/encoding.ts CHANGED
@@ -3,6 +3,7 @@ import {
3
3
  decodeAbiParameters,
4
4
  encodeAbiParameters,
5
5
  encodeFunctionData,
6
+ getAbiItem,
6
7
  } from "viem";
7
8
  import {
8
9
  uniswapV3SwapRouterABI,
@@ -197,16 +198,17 @@ export const encodeMultiCurvePoolConfig = ({
197
198
  numDiscoveryPositions: number[];
198
199
  maxDiscoverySupplyShare: bigint[];
199
200
  }) => {
200
- return encodeFunctionData({
201
+ const abiItem = getAbiItem({
201
202
  abi: poolConfigEncodingABI,
202
- functionName: "encodeMultiCurvePoolConfig",
203
- args: [
204
- UNISWAP_V4_MULTICURVE_POOL_VERSION,
205
- currency,
206
- tickLower,
207
- tickUpper,
208
- numDiscoveryPositions,
209
- maxDiscoverySupplyShare,
210
- ],
203
+ name: "encodeMultiCurvePoolConfig",
211
204
  });
205
+
206
+ return encodeAbiParameters(abiItem.inputs, [
207
+ UNISWAP_V4_MULTICURVE_POOL_VERSION,
208
+ currency,
209
+ tickLower,
210
+ tickUpper,
211
+ numDiscoveryPositions,
212
+ maxDiscoverySupplyShare,
213
+ ]);
212
214
  };