File tree Expand file tree Collapse file tree 2 files changed +27
-3
lines changed
Expand file tree Collapse file tree 2 files changed +27
-3
lines changed Original file line number Diff line number Diff line change @@ -98,6 +98,22 @@ export const iaclAbi = [
9898 } ,
9999] as const ;
100100
101+ export const iaclTraitAbi = [
102+ {
103+ type : "function" ,
104+ name : "acl" ,
105+ inputs : [ ] ,
106+ outputs : [
107+ {
108+ name : "" ,
109+ type : "address" ,
110+ internalType : "address" ,
111+ } ,
112+ ] ,
113+ stateMutability : "view" ,
114+ } ,
115+ ] as const ;
116+
101117export const iCreditConfiguratorV3Abi = [
102118 {
103119 type : "function" ,
Original file line number Diff line number Diff line change @@ -2,8 +2,12 @@ import type { Address } from "viem";
22import { parseEther } from "viem" ;
33
44import type { CreditFactory , GearboxSDK , ILogger } from "../sdk" ;
5- import { AP_ACL } from "../sdk" ;
6- import { iaclAbi , iCreditConfiguratorV3Abi , iCreditManagerV3Abi } from "./abi" ;
5+ import {
6+ iaclAbi ,
7+ iaclTraitAbi ,
8+ iCreditConfiguratorV3Abi ,
9+ iCreditManagerV3Abi ,
10+ } from "./abi" ;
711import { createAnvilClient } from "./createAnvilClient" ;
812
913/**
@@ -18,7 +22,11 @@ export async function setLTs(
1822 newLTs : Record < Address , number > ,
1923 logger ?: ILogger ,
2024) : Promise < void > {
21- const aclAddr = sdk . addressProvider . getLatestVersion ( AP_ACL ) ;
25+ const aclAddr = await sdk . provider . publicClient . readContract ( {
26+ address : cm . creditConfigurator . address ,
27+ abi : iaclTraitAbi ,
28+ functionName : "acl" ,
29+ } ) ;
2230 const configuratorAddr = await sdk . provider . publicClient . readContract ( {
2331 address : aclAddr ,
2432 abi : iaclAbi ,
You can’t perform that action at this time.
0 commit comments