@instadapp/avocado-base 0.0.21 → 0.0.24
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/abi/forwarder.json +1253 -149
- package/contracts/Forwarder.ts +856 -2
- package/contracts/factories/Forwarder__factory.ts +816 -16
- package/package.json +1 -1
- package/utils/metadata.ts +12 -2
package/package.json
CHANGED
package/utils/metadata.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ethers, utils } from "ethers";
|
|
2
|
-
import { Forwarder__factory } from "
|
|
2
|
+
import { Forwarder__factory } from "../contracts";
|
|
3
3
|
|
|
4
4
|
const multiMetadataTypes = ["bytes[]"];
|
|
5
5
|
|
|
@@ -238,7 +238,7 @@ export const decodeMetadata = (data: string) => {
|
|
|
238
238
|
} else {
|
|
239
239
|
metadata = executeData.metadata_;
|
|
240
240
|
}
|
|
241
|
-
} else {
|
|
241
|
+
} else if (data.startsWith("0x14f80a8d")) {
|
|
242
242
|
const executeDataV2 = iface.decodeFunctionData("executeV2", data);
|
|
243
243
|
if (
|
|
244
244
|
executeDataV2.params_.metadata === "0x" ||
|
|
@@ -248,6 +248,16 @@ export const decodeMetadata = (data: string) => {
|
|
|
248
248
|
} else {
|
|
249
249
|
metadata = executeDataV2.params_.metadata;
|
|
250
250
|
}
|
|
251
|
+
} else {
|
|
252
|
+
const executeDataV3 = iface.decodeFunctionData("executeV3", data);
|
|
253
|
+
if (
|
|
254
|
+
executeDataV3.params_.metadata === "0x" ||
|
|
255
|
+
!executeDataV3.params_.metadata
|
|
256
|
+
) {
|
|
257
|
+
return null;
|
|
258
|
+
} else {
|
|
259
|
+
metadata = executeDataV3.params_.metadata;
|
|
260
|
+
}
|
|
251
261
|
}
|
|
252
262
|
|
|
253
263
|
const metadataArr = [];
|