@@ -63,92 +63,80 @@ export default class ContractFactory {
63
63
public async getModuleContract ( address : string ) : Promise < ModuleContract > {
64
64
assert . isETHAddressHex ( 'address' , address ) ;
65
65
const contract = new ModuleContract ( address , this . provider , this . contractDefaults ) ;
66
- this . abiArray . forEach (
67
- ( abi ) : void => {
68
- contract . addABItoDecoder ( abi ) ;
69
- } ,
70
- ) ;
66
+ this . abiArray . forEach ( ( abi ) : void => {
67
+ contract . addABItoDecoder ( abi ) ;
68
+ } ) ;
71
69
return contract ;
72
70
}
73
71
74
72
public async getERC20DividendCheckpointContract ( address : string ) : Promise < ERC20DividendCheckpointContract > {
75
73
assert . isETHAddressHex ( 'address' , address ) ;
76
74
const contract = new ERC20DividendCheckpointContract ( address , this . provider , this . contractDefaults ) ;
77
- this . abiArray . forEach (
78
- ( abi ) : void => {
79
- contract . addABItoDecoder ( abi ) ;
80
- } ,
81
- ) ;
75
+ this . abiArray . forEach ( ( abi ) : void => {
76
+ contract . addABItoDecoder ( abi ) ;
77
+ } ) ;
82
78
return contract ;
83
79
}
84
80
85
81
public async getPolymathRegistryContract ( ) : Promise < PolymathRegistryContract > {
86
82
const contract = await this . polymathRegistry ;
87
- this . abiArray . forEach (
88
- ( abi ) : void => {
89
- contract . addABItoDecoder ( abi ) ;
90
- } ,
91
- ) ;
83
+ this . abiArray . forEach ( ( abi ) : void => {
84
+ contract . addABItoDecoder ( abi ) ;
85
+ } ) ;
92
86
return contract ;
93
87
}
94
88
95
89
public async getModuleFactoryContract ( address : string ) : Promise < ModuleFactoryContract > {
96
90
assert . isETHAddressHex ( 'address' , address ) ;
97
91
const contract = new ModuleFactoryContract ( address , this . provider , this . contractDefaults ) ;
98
- this . abiArray . forEach (
99
- ( abi ) : void => {
100
- contract . addABItoDecoder ( abi ) ;
101
- } ,
102
- ) ;
92
+ this . abiArray . forEach ( ( abi ) : void => {
93
+ contract . addABItoDecoder ( abi ) ;
94
+ } ) ;
103
95
return contract ;
104
96
}
105
97
106
98
public async getEtherDividendCheckpointContract ( address : string ) : Promise < EtherDividendCheckpointContract > {
107
99
assert . isETHAddressHex ( 'address' , address ) ;
108
100
const contract = new EtherDividendCheckpointContract ( address , this . provider , this . contractDefaults ) ;
109
- this . abiArray . forEach (
110
- ( abi ) : void => {
111
- contract . addABItoDecoder ( abi ) ;
112
- } ,
113
- ) ;
101
+ this . abiArray . forEach ( ( abi ) : void => {
102
+ contract . addABItoDecoder ( abi ) ;
103
+ } ) ;
114
104
return contract ;
115
105
}
116
106
117
107
public async getVestingEscrowWalletContract ( address : string ) : Promise < VestingEscrowWalletContract > {
118
108
assert . isETHAddressHex ( 'address' , address ) ;
119
- return new VestingEscrowWalletContract ( address , this . provider , this . contractDefaults ) ;
109
+ const contract = new VestingEscrowWalletContract ( address , this . provider , this . contractDefaults ) ;
110
+ this . abiArray . forEach ( ( abi ) : void => {
111
+ contract . addABItoDecoder ( abi ) ;
112
+ } ) ;
113
+ return contract ;
120
114
}
121
115
122
116
public async getERC20DetailedContract ( address : string ) : Promise < ERC20DetailedContract > {
123
117
assert . isETHAddressHex ( 'address' , address ) ;
124
118
const contract = new ERC20DetailedContract ( address , this . provider , this . contractDefaults ) ;
125
- this . abiArray . forEach (
126
- ( abi ) : void => {
127
- contract . addABItoDecoder ( abi ) ;
128
- } ,
129
- ) ;
119
+ this . abiArray . forEach ( ( abi ) : void => {
120
+ contract . addABItoDecoder ( abi ) ;
121
+ } ) ;
130
122
return contract ;
131
123
}
132
124
133
125
public async getAlternativeERC20Contract ( address : string ) : Promise < ERC20DetailedContract > {
134
126
assert . isETHAddressHex ( 'address' , address ) ;
135
127
const contract = new ERC20DetailedContract ( address , this . provider , this . contractDefaults ) ;
136
- this . abiArray . forEach (
137
- ( abi ) : void => {
138
- contract . addABItoDecoder ( abi ) ;
139
- } ,
140
- ) ;
128
+ this . abiArray . forEach ( ( abi ) : void => {
129
+ contract . addABItoDecoder ( abi ) ;
130
+ } ) ;
141
131
return contract ;
142
132
}
143
133
144
134
public async getSecurityTokenContract ( address : string ) : Promise < ISecurityTokenContract > {
145
135
assert . isETHAddressHex ( 'address' , address ) ;
146
136
const contract = new ISecurityTokenContract ( address , this . provider , this . contractDefaults ) ;
147
- this . abiArray . forEach (
148
- ( abi ) : void => {
149
- contract . addABItoDecoder ( abi ) ;
150
- } ,
151
- ) ;
137
+ this . abiArray . forEach ( ( abi ) : void => {
138
+ contract . addABItoDecoder ( abi ) ;
139
+ } ) ;
152
140
return contract ;
153
141
}
154
142
@@ -158,11 +146,9 @@ export default class ContractFactory {
158
146
this . provider ,
159
147
this . contractDefaults ,
160
148
) ;
161
- this . abiArray . forEach (
162
- ( abi ) : void => {
163
- contract . addABItoDecoder ( abi ) ;
164
- } ,
165
- ) ;
149
+ this . abiArray . forEach ( ( abi ) : void => {
150
+ contract . addABItoDecoder ( abi ) ;
151
+ } ) ;
166
152
return contract ;
167
153
}
168
154
@@ -172,88 +158,71 @@ export default class ContractFactory {
172
158
this . provider ,
173
159
this . contractDefaults ,
174
160
) ;
175
- this . abiArray . forEach (
176
- ( abi ) : void => {
177
-
178
- contract . addABItoDecoder ( abi ) ;
179
- } ,
180
- ) ;
161
+ this . abiArray . forEach ( ( abi ) : void => {
162
+ contract . addABItoDecoder ( abi ) ;
163
+ } ) ;
181
164
return contract ;
182
165
}
183
166
184
167
public async getGeneralPermissionManagerContract ( address : string ) : Promise < GeneralPermissionManagerContract > {
185
168
assert . isETHAddressHex ( 'address' , address ) ;
186
169
const contract = new GeneralPermissionManagerContract ( address , this . provider , this . contractDefaults ) ;
187
- this . abiArray . forEach (
188
- ( abi ) : void => {
189
- contract . addABItoDecoder ( abi ) ;
190
- } ,
191
- ) ;
170
+ this . abiArray . forEach ( ( abi ) : void => {
171
+ contract . addABItoDecoder ( abi ) ;
172
+ } ) ;
192
173
return contract ;
193
174
}
194
175
195
176
public async getCappedSTOFactoryContract ( address : string ) : Promise < CappedSTOFactoryContract > {
196
177
const contract = new CappedSTOFactoryContract ( address , this . provider , this . contractDefaults ) ;
197
- this . abiArray . forEach (
198
- ( abi ) : void => {
199
- contract . addABItoDecoder ( abi ) ;
200
- } ,
201
- ) ;
178
+ this . abiArray . forEach ( ( abi ) : void => {
179
+ contract . addABItoDecoder ( abi ) ;
180
+ } ) ;
202
181
return contract ;
203
182
}
204
183
205
184
public async getCappedSTOContract ( address : string ) : Promise < CappedSTOContract > {
206
185
assert . isETHAddressHex ( 'address' , address ) ;
207
186
const contract = new CappedSTOContract ( address , this . provider , this . contractDefaults ) ;
208
- this . abiArray . forEach (
209
- ( abi ) : void => {
210
- contract . addABItoDecoder ( abi ) ;
211
- } ,
212
- ) ;
187
+ this . abiArray . forEach ( ( abi ) : void => {
188
+ contract . addABItoDecoder ( abi ) ;
189
+ } ) ;
213
190
return contract ;
214
191
}
215
192
216
193
public async getUSDTieredSTOFactoryContract ( address : string ) : Promise < USDTieredSTOFactoryContract > {
217
194
assert . isETHAddressHex ( 'address' , address ) ;
218
195
const contract = new USDTieredSTOFactoryContract ( address , this . provider , this . contractDefaults ) ;
219
- this . abiArray . forEach (
220
- ( abi ) : void => {
221
- contract . addABItoDecoder ( abi ) ;
222
- } ,
223
- ) ;
196
+ this . abiArray . forEach ( ( abi ) : void => {
197
+ contract . addABItoDecoder ( abi ) ;
198
+ } ) ;
224
199
return contract ;
225
200
}
226
201
227
202
public async getUSDTieredSTOContract ( address : string ) : Promise < USDTieredSTOContract > {
228
203
assert . isETHAddressHex ( 'address' , address ) ;
229
204
const contract = new USDTieredSTOContract ( address , this . provider , this . contractDefaults ) ;
230
- this . abiArray . forEach (
231
- ( abi ) : void => {
232
- contract . addABItoDecoder ( abi ) ;
233
- } ,
234
- ) ;
205
+ this . abiArray . forEach ( ( abi ) : void => {
206
+ contract . addABItoDecoder ( abi ) ;
207
+ } ) ;
235
208
return contract ;
236
209
}
237
210
238
211
public async getCountTransferManagerContract ( address : string ) : Promise < CountTransferManagerContract > {
239
212
assert . isETHAddressHex ( 'address' , address ) ;
240
213
const contract = new CountTransferManagerContract ( address , this . provider , this . contractDefaults ) ;
241
- this . abiArray . forEach (
242
- ( abi ) : void => {
243
- contract . addABItoDecoder ( abi ) ;
244
- } ,
245
- ) ;
214
+ this . abiArray . forEach ( ( abi ) : void => {
215
+ contract . addABItoDecoder ( abi ) ;
216
+ } ) ;
246
217
return contract ;
247
218
}
248
219
249
220
public async getGeneralTransferManagerContract ( address : string ) : Promise < GeneralTransferManagerContract > {
250
221
assert . isETHAddressHex ( 'address' , address ) ;
251
222
const contract = new GeneralTransferManagerContract ( address , this . provider , this . contractDefaults ) ;
252
- this . abiArray . forEach (
253
- ( abi ) : void => {
254
- contract . addABItoDecoder ( abi ) ;
255
- } ,
256
- ) ;
223
+ this . abiArray . forEach ( ( abi ) : void => {
224
+ contract . addABItoDecoder ( abi ) ;
225
+ } ) ;
257
226
return contract ;
258
227
}
259
228
@@ -262,56 +231,45 @@ export default class ContractFactory {
262
231
) : Promise < ManualApprovalTransferManagerContract > {
263
232
assert . isETHAddressHex ( 'address' , address ) ;
264
233
const contract = new ManualApprovalTransferManagerContract ( address , this . provider , this . contractDefaults ) ;
265
- this . abiArray . forEach (
266
- ( abi ) : void => {
267
- contract . addABItoDecoder ( abi ) ;
268
- } ,
269
- ) ;
234
+ this . abiArray . forEach ( ( abi ) : void => {
235
+ contract . addABItoDecoder ( abi ) ;
236
+ } ) ;
270
237
return contract ;
271
238
}
272
239
273
240
public async getPercentageTransferManagerContract ( address : string ) : Promise < PercentageTransferManagerContract > {
274
241
assert . isETHAddressHex ( 'address' , address ) ;
275
242
const contract = new PercentageTransferManagerContract ( address , this . provider , this . contractDefaults ) ;
276
- this . abiArray . forEach (
277
- ( abi ) : void => {
278
- contract . addABItoDecoder ( abi ) ;
279
- } ,
280
- ) ;
243
+ this . abiArray . forEach ( ( abi ) : void => {
244
+ contract . addABItoDecoder ( abi ) ;
245
+ } ) ;
281
246
return contract ;
282
247
}
283
248
284
-
285
249
public async getLockUpTransferManagerContract ( address : string ) : Promise < LockUpTransferManagerContract > {
286
250
assert . isETHAddressHex ( 'address' , address ) ;
287
251
const contract = new LockUpTransferManagerContract ( address , this . provider , this . contractDefaults ) ;
288
- this . abiArray . forEach (
289
- ( abi ) : void => {
290
- contract . addABItoDecoder ( abi ) ;
291
- } ,
292
- ) ;
252
+ this . abiArray . forEach ( ( abi ) : void => {
253
+ contract . addABItoDecoder ( abi ) ;
254
+ } ) ;
293
255
return contract ;
294
256
}
295
257
296
258
public async getBlacklistTransferManagerContract ( address : string ) : Promise < BlacklistTransferManagerContract > {
297
259
assert . isETHAddressHex ( 'address' , address ) ;
298
260
const contract = new BlacklistTransferManagerContract ( address , this . provider , this . contractDefaults ) ;
299
- this . abiArray . forEach (
300
- ( abi ) : void => {
301
- contract . addABItoDecoder ( abi ) ;
302
- } ,
303
- ) ;
261
+ this . abiArray . forEach ( ( abi ) : void => {
262
+ contract . addABItoDecoder ( abi ) ;
263
+ } ) ;
304
264
return contract ;
305
265
}
306
-
266
+
307
267
public async getVolumeRestrictionTMContract ( address : string ) : Promise < VolumeRestrictionTMContract > {
308
268
assert . isETHAddressHex ( 'address' , address ) ;
309
269
const contract = new VolumeRestrictionTMContract ( address , this . provider , this . contractDefaults ) ;
310
- this . abiArray . forEach (
311
- ( abi ) : void => {
312
- contract . addABItoDecoder ( abi ) ;
313
- } ,
314
- ) ;
270
+ this . abiArray . forEach ( ( abi ) : void => {
271
+ contract . addABItoDecoder ( abi ) ;
272
+ } ) ;
315
273
return contract ;
316
274
}
317
275
@@ -321,11 +279,9 @@ export default class ContractFactory {
321
279
this . provider ,
322
280
this . contractDefaults ,
323
281
) ;
324
- this . abiArray . forEach (
325
- ( abi ) : void => {
326
- contract . addABItoDecoder ( abi ) ;
327
- } ,
328
- ) ;
282
+ this . abiArray . forEach ( ( abi ) : void => {
283
+ contract . addABItoDecoder ( abi ) ;
284
+ } ) ;
329
285
return contract ;
330
286
}
331
287
@@ -335,11 +291,9 @@ export default class ContractFactory {
335
291
this . provider ,
336
292
this . contractDefaults ,
337
293
) ;
338
- this . abiArray . forEach (
339
- ( abi ) : void => {
340
- contract . addABItoDecoder ( abi ) ;
341
- } ,
342
- ) ;
294
+ this . abiArray . forEach ( ( abi ) : void => {
295
+ contract . addABItoDecoder ( abi ) ;
296
+ } ) ;
343
297
return contract ;
344
298
}
345
299
@@ -349,11 +303,9 @@ export default class ContractFactory {
349
303
this . provider ,
350
304
this . contractDefaults ,
351
305
) ;
352
- this . abiArray . forEach (
353
- ( abi ) : void => {
354
- contract . addABItoDecoder ( abi ) ;
355
- } ,
356
- ) ;
306
+ this . abiArray . forEach ( ( abi ) : void => {
307
+ contract . addABItoDecoder ( abi ) ;
308
+ } ) ;
357
309
return contract ;
358
310
}
359
311
}
0 commit comments