@sentio/sdk 2.40.0-rc.35 → 2.40.0-rc.37
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/lib/eth/builtin/internal/eacaggregatorproxy-processor.d.ts.map +1 -1
- package/lib/eth/builtin/internal/eacaggregatorproxy-processor.js +0 -69
- package/lib/eth/builtin/internal/eacaggregatorproxy-processor.js.map +1 -1
- package/lib/eth/builtin/internal/erc1155-processor.d.ts.map +1 -1
- package/lib/eth/builtin/internal/erc1155-processor.js +0 -24
- package/lib/eth/builtin/internal/erc1155-processor.js.map +1 -1
- package/lib/eth/builtin/internal/erc20-processor.d.ts.map +1 -1
- package/lib/eth/builtin/internal/erc20-processor.js +0 -54
- package/lib/eth/builtin/internal/erc20-processor.js.map +1 -1
- package/lib/eth/builtin/internal/erc20bytes-processor.d.ts.map +1 -1
- package/lib/eth/builtin/internal/erc20bytes-processor.js +0 -27
- package/lib/eth/builtin/internal/erc20bytes-processor.js.map +1 -1
- package/lib/eth/builtin/internal/erc721-processor.d.ts.map +1 -1
- package/lib/eth/builtin/internal/erc721-processor.js +0 -42
- package/lib/eth/builtin/internal/erc721-processor.js.map +1 -1
- package/lib/eth/builtin/internal/weth9-processor.d.ts.map +1 -1
- package/lib/eth/builtin/internal/weth9-processor.js +0 -33
- package/lib/eth/builtin/internal/weth9-processor.js.map +1 -1
- package/lib/eth/codegen/function-calls.d.ts.map +1 -1
- package/lib/eth/codegen/function-calls.js +0 -3
- package/lib/eth/codegen/function-calls.js.map +1 -1
- package/lib/tsup.config.ts +1 -15
- package/package.json +6 -3
- package/src/bundle.config.ts +22 -0
- package/src/eth/builtin/internal/eacaggregatorproxy-processor.ts +0 -89
- package/src/eth/builtin/internal/erc1155-processor.ts +0 -65
- package/src/eth/builtin/internal/erc20-processor.ts +0 -102
- package/src/eth/builtin/internal/erc20bytes-processor.ts +0 -46
- package/src/eth/builtin/internal/erc721-processor.ts +0 -81
- package/src/eth/builtin/internal/weth9-processor.ts +0 -40
- package/src/eth/codegen/function-calls.ts +0 -5
- package/src/tsup.config.ts +1 -15
@@ -193,20 +193,11 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
193
193
|
context: ethCallContext,
|
194
194
|
calldata,
|
195
195
|
});
|
196
|
-
console.debug("looking up eth call key:", key);
|
197
196
|
const ret = preparedData.ethCallResults[key];
|
198
197
|
if (ret) {
|
199
|
-
console.debug("prepared eth call found:", key);
|
200
198
|
const result = iface.decodeFunctionResult("allowance", ret).toArray();
|
201
199
|
return result.length == 1 ? result[0] : result;
|
202
200
|
}
|
203
|
-
console.debug(
|
204
|
-
"missing eth call key:",
|
205
|
-
"allowance",
|
206
|
-
owner,
|
207
|
-
spender,
|
208
|
-
key
|
209
|
-
);
|
210
201
|
}
|
211
202
|
return await this.contract.getFunction("allowance(address,address)")(
|
212
203
|
owner,
|
@@ -235,14 +226,11 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
235
226
|
context: ethCallContext,
|
236
227
|
calldata,
|
237
228
|
});
|
238
|
-
console.debug("looking up eth call key:", key);
|
239
229
|
const ret = preparedData.ethCallResults[key];
|
240
230
|
if (ret) {
|
241
|
-
console.debug("prepared eth call found:", key);
|
242
231
|
const result = iface.decodeFunctionResult("balanceOf", ret).toArray();
|
243
232
|
return result.length == 1 ? result[0] : result;
|
244
233
|
}
|
245
|
-
console.debug("missing eth call key:", "balanceOf", account, key);
|
246
234
|
}
|
247
235
|
return await this.contract.getFunction("balanceOf(address)")(
|
248
236
|
account,
|
@@ -269,14 +257,11 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
269
257
|
context: ethCallContext,
|
270
258
|
calldata,
|
271
259
|
});
|
272
|
-
console.debug("looking up eth call key:", key);
|
273
260
|
const ret = preparedData.ethCallResults[key];
|
274
261
|
if (ret) {
|
275
|
-
console.debug("prepared eth call found:", key);
|
276
262
|
const result = iface.decodeFunctionResult("decimals", ret).toArray();
|
277
263
|
return result.length == 1 ? result[0] : result;
|
278
264
|
}
|
279
|
-
console.debug("missing eth call key:", "decimals", key);
|
280
265
|
}
|
281
266
|
return await this.contract.getFunction("decimals()")(overrides || {});
|
282
267
|
} catch (e) {
|
@@ -300,14 +285,11 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
300
285
|
context: ethCallContext,
|
301
286
|
calldata,
|
302
287
|
});
|
303
|
-
console.debug("looking up eth call key:", key);
|
304
288
|
const ret = preparedData.ethCallResults[key];
|
305
289
|
if (ret) {
|
306
|
-
console.debug("prepared eth call found:", key);
|
307
290
|
const result = iface.decodeFunctionResult("locker", ret).toArray();
|
308
291
|
return result.length == 1 ? result[0] : result;
|
309
292
|
}
|
310
|
-
console.debug("missing eth call key:", "locker", key);
|
311
293
|
}
|
312
294
|
return await this.contract.getFunction("locker()")(overrides || {});
|
313
295
|
} catch (e) {
|
@@ -329,14 +311,11 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
329
311
|
context: ethCallContext,
|
330
312
|
calldata,
|
331
313
|
});
|
332
|
-
console.debug("looking up eth call key:", key);
|
333
314
|
const ret = preparedData.ethCallResults[key];
|
334
315
|
if (ret) {
|
335
|
-
console.debug("prepared eth call found:", key);
|
336
316
|
const result = iface.decodeFunctionResult("name", ret).toArray();
|
337
317
|
return result.length == 1 ? result[0] : result;
|
338
318
|
}
|
339
|
-
console.debug("missing eth call key:", "name", key);
|
340
319
|
}
|
341
320
|
return await this.contract.getFunction("name()")(overrides || {});
|
342
321
|
} catch (e) {
|
@@ -360,14 +339,11 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
360
339
|
context: ethCallContext,
|
361
340
|
calldata,
|
362
341
|
});
|
363
|
-
console.debug("looking up eth call key:", key);
|
364
342
|
const ret = preparedData.ethCallResults[key];
|
365
343
|
if (ret) {
|
366
|
-
console.debug("prepared eth call found:", key);
|
367
344
|
const result = iface.decodeFunctionResult("owner", ret).toArray();
|
368
345
|
return result.length == 1 ? result[0] : result;
|
369
346
|
}
|
370
|
-
console.debug("missing eth call key:", "owner", key);
|
371
347
|
}
|
372
348
|
return await this.contract.getFunction("owner()")(overrides || {});
|
373
349
|
} catch (e) {
|
@@ -391,14 +367,11 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
391
367
|
context: ethCallContext,
|
392
368
|
calldata,
|
393
369
|
});
|
394
|
-
console.debug("looking up eth call key:", key);
|
395
370
|
const ret = preparedData.ethCallResults[key];
|
396
371
|
if (ret) {
|
397
|
-
console.debug("prepared eth call found:", key);
|
398
372
|
const result = iface.decodeFunctionResult("symbol", ret).toArray();
|
399
373
|
return result.length == 1 ? result[0] : result;
|
400
374
|
}
|
401
|
-
console.debug("missing eth call key:", "symbol", key);
|
402
375
|
}
|
403
376
|
return await this.contract.getFunction("symbol()")(overrides || {});
|
404
377
|
} catch (e) {
|
@@ -422,16 +395,13 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
422
395
|
context: ethCallContext,
|
423
396
|
calldata,
|
424
397
|
});
|
425
|
-
console.debug("looking up eth call key:", key);
|
426
398
|
const ret = preparedData.ethCallResults[key];
|
427
399
|
if (ret) {
|
428
|
-
console.debug("prepared eth call found:", key);
|
429
400
|
const result = iface
|
430
401
|
.decodeFunctionResult("totalSupply", ret)
|
431
402
|
.toArray();
|
432
403
|
return result.length == 1 ? result[0] : result;
|
433
404
|
}
|
434
|
-
console.debug("missing eth call key:", "totalSupply", key);
|
435
405
|
}
|
436
406
|
return await this.contract.getFunction("totalSupply()")(overrides || {});
|
437
407
|
} catch (e) {
|
@@ -463,20 +433,11 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
463
433
|
context: ethCallContext,
|
464
434
|
calldata,
|
465
435
|
});
|
466
|
-
console.debug("looking up eth call key:", key);
|
467
436
|
const ret = preparedData.ethCallResults[key];
|
468
437
|
if (ret) {
|
469
|
-
console.debug("prepared eth call found:", key);
|
470
438
|
const result = iface.decodeFunctionResult("approve", ret).toArray();
|
471
439
|
return result.length == 1 ? result[0] : result;
|
472
440
|
}
|
473
|
-
console.debug(
|
474
|
-
"missing eth call key:",
|
475
|
-
"approve",
|
476
|
-
spender,
|
477
|
-
amount,
|
478
|
-
key
|
479
|
-
);
|
480
441
|
}
|
481
442
|
return await this.contract
|
482
443
|
.getFunction("approve(address,uint256)")
|
@@ -502,14 +463,11 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
502
463
|
context: ethCallContext,
|
503
464
|
calldata,
|
504
465
|
});
|
505
|
-
console.debug("looking up eth call key:", key);
|
506
466
|
const ret = preparedData.ethCallResults[key];
|
507
467
|
if (ret) {
|
508
|
-
console.debug("prepared eth call found:", key);
|
509
468
|
const result = iface.decodeFunctionResult("burn", ret).toArray();
|
510
469
|
return result.length == 1 ? result[0] : result;
|
511
470
|
}
|
512
|
-
console.debug("missing eth call key:", "burn", amount, key);
|
513
471
|
}
|
514
472
|
return await this.contract
|
515
473
|
.getFunction("burn(uint256)")
|
@@ -539,22 +497,13 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
539
497
|
context: ethCallContext,
|
540
498
|
calldata,
|
541
499
|
});
|
542
|
-
console.debug("looking up eth call key:", key);
|
543
500
|
const ret = preparedData.ethCallResults[key];
|
544
501
|
if (ret) {
|
545
|
-
console.debug("prepared eth call found:", key);
|
546
502
|
const result = iface
|
547
503
|
.decodeFunctionResult("burnFrom", ret)
|
548
504
|
.toArray();
|
549
505
|
return result.length == 1 ? result[0] : result;
|
550
506
|
}
|
551
|
-
console.debug(
|
552
|
-
"missing eth call key:",
|
553
|
-
"burnFrom",
|
554
|
-
account,
|
555
|
-
amount,
|
556
|
-
key
|
557
|
-
);
|
558
507
|
}
|
559
508
|
return await this.contract
|
560
509
|
.getFunction("burnFrom(address,uint256)")
|
@@ -584,22 +533,13 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
584
533
|
context: ethCallContext,
|
585
534
|
calldata,
|
586
535
|
});
|
587
|
-
console.debug("looking up eth call key:", key);
|
588
536
|
const ret = preparedData.ethCallResults[key];
|
589
537
|
if (ret) {
|
590
|
-
console.debug("prepared eth call found:", key);
|
591
538
|
const result = iface
|
592
539
|
.decodeFunctionResult("decreaseAllowance", ret)
|
593
540
|
.toArray();
|
594
541
|
return result.length == 1 ? result[0] : result;
|
595
542
|
}
|
596
|
-
console.debug(
|
597
|
-
"missing eth call key:",
|
598
|
-
"decreaseAllowance",
|
599
|
-
spender,
|
600
|
-
subtractedValue,
|
601
|
-
key
|
602
|
-
);
|
603
543
|
}
|
604
544
|
return await this.contract
|
605
545
|
.getFunction("decreaseAllowance(address,uint256)")
|
@@ -629,22 +569,13 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
629
569
|
context: ethCallContext,
|
630
570
|
calldata,
|
631
571
|
});
|
632
|
-
console.debug("looking up eth call key:", key);
|
633
572
|
const ret = preparedData.ethCallResults[key];
|
634
573
|
if (ret) {
|
635
|
-
console.debug("prepared eth call found:", key);
|
636
574
|
const result = iface
|
637
575
|
.decodeFunctionResult("increaseAllowance", ret)
|
638
576
|
.toArray();
|
639
577
|
return result.length == 1 ? result[0] : result;
|
640
578
|
}
|
641
|
-
console.debug(
|
642
|
-
"missing eth call key:",
|
643
|
-
"increaseAllowance",
|
644
|
-
spender,
|
645
|
-
addedValue,
|
646
|
-
key
|
647
|
-
);
|
648
579
|
}
|
649
580
|
return await this.contract
|
650
581
|
.getFunction("increaseAllowance(address,uint256)")
|
@@ -669,16 +600,13 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
669
600
|
context: ethCallContext,
|
670
601
|
calldata,
|
671
602
|
});
|
672
|
-
console.debug("looking up eth call key:", key);
|
673
603
|
const ret = preparedData.ethCallResults[key];
|
674
604
|
if (ret) {
|
675
|
-
console.debug("prepared eth call found:", key);
|
676
605
|
const result = iface
|
677
606
|
.decodeFunctionResult("renounceOwnership", ret)
|
678
607
|
.toArray();
|
679
608
|
return result.length == 1 ? result[0] : result;
|
680
609
|
}
|
681
|
-
console.debug("missing eth call key:", "renounceOwnership", key);
|
682
610
|
}
|
683
611
|
return await this.contract
|
684
612
|
.getFunction("renounceOwnership()")
|
@@ -704,16 +632,13 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
704
632
|
context: ethCallContext,
|
705
633
|
calldata,
|
706
634
|
});
|
707
|
-
console.debug("looking up eth call key:", key);
|
708
635
|
const ret = preparedData.ethCallResults[key];
|
709
636
|
if (ret) {
|
710
|
-
console.debug("prepared eth call found:", key);
|
711
637
|
const result = iface
|
712
638
|
.decodeFunctionResult("setLocker", ret)
|
713
639
|
.toArray();
|
714
640
|
return result.length == 1 ? result[0] : result;
|
715
641
|
}
|
716
|
-
console.debug("missing eth call key:", "setLocker", _locker, key);
|
717
642
|
}
|
718
643
|
return await this.contract
|
719
644
|
.getFunction("setLocker(address)")
|
@@ -743,22 +668,13 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
743
668
|
context: ethCallContext,
|
744
669
|
calldata,
|
745
670
|
});
|
746
|
-
console.debug("looking up eth call key:", key);
|
747
671
|
const ret = preparedData.ethCallResults[key];
|
748
672
|
if (ret) {
|
749
|
-
console.debug("prepared eth call found:", key);
|
750
673
|
const result = iface
|
751
674
|
.decodeFunctionResult("transfer", ret)
|
752
675
|
.toArray();
|
753
676
|
return result.length == 1 ? result[0] : result;
|
754
677
|
}
|
755
|
-
console.debug(
|
756
|
-
"missing eth call key:",
|
757
|
-
"transfer",
|
758
|
-
recipient,
|
759
|
-
amount,
|
760
|
-
key
|
761
|
-
);
|
762
678
|
}
|
763
679
|
return await this.contract
|
764
680
|
.getFunction("transfer(address,uint256)")
|
@@ -790,23 +706,13 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
790
706
|
context: ethCallContext,
|
791
707
|
calldata,
|
792
708
|
});
|
793
|
-
console.debug("looking up eth call key:", key);
|
794
709
|
const ret = preparedData.ethCallResults[key];
|
795
710
|
if (ret) {
|
796
|
-
console.debug("prepared eth call found:", key);
|
797
711
|
const result = iface
|
798
712
|
.decodeFunctionResult("transferFrom", ret)
|
799
713
|
.toArray();
|
800
714
|
return result.length == 1 ? result[0] : result;
|
801
715
|
}
|
802
|
-
console.debug(
|
803
|
-
"missing eth call key:",
|
804
|
-
"transferFrom",
|
805
|
-
sender,
|
806
|
-
recipient,
|
807
|
-
amount,
|
808
|
-
key
|
809
|
-
);
|
810
716
|
}
|
811
717
|
return await this.contract
|
812
718
|
.getFunction("transferFrom(address,address,uint256)")
|
@@ -834,21 +740,13 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
834
740
|
context: ethCallContext,
|
835
741
|
calldata,
|
836
742
|
});
|
837
|
-
console.debug("looking up eth call key:", key);
|
838
743
|
const ret = preparedData.ethCallResults[key];
|
839
744
|
if (ret) {
|
840
|
-
console.debug("prepared eth call found:", key);
|
841
745
|
const result = iface
|
842
746
|
.decodeFunctionResult("transferOwnership", ret)
|
843
747
|
.toArray();
|
844
748
|
return result.length == 1 ? result[0] : result;
|
845
749
|
}
|
846
|
-
console.debug(
|
847
|
-
"missing eth call key:",
|
848
|
-
"transferOwnership",
|
849
|
-
newOwner,
|
850
|
-
key
|
851
|
-
);
|
852
750
|
}
|
853
751
|
return await this.contract
|
854
752
|
.getFunction("transferOwnership(address)")
|
@@ -118,14 +118,11 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
118
118
|
context: ethCallContext,
|
119
119
|
calldata,
|
120
120
|
});
|
121
|
-
console.debug("looking up eth call key:", key);
|
122
121
|
const ret = preparedData.ethCallResults[key];
|
123
122
|
if (ret) {
|
124
|
-
console.debug("prepared eth call found:", key);
|
125
123
|
const result = iface.decodeFunctionResult("name", ret).toArray();
|
126
124
|
return result.length == 1 ? result[0] : result;
|
127
125
|
}
|
128
|
-
console.debug("missing eth call key:", "name", key);
|
129
126
|
}
|
130
127
|
return await this.contract.getFunction("name()")(overrides || {});
|
131
128
|
} catch (e) {
|
@@ -149,16 +146,13 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
149
146
|
context: ethCallContext,
|
150
147
|
calldata,
|
151
148
|
});
|
152
|
-
console.debug("looking up eth call key:", key);
|
153
149
|
const ret = preparedData.ethCallResults[key];
|
154
150
|
if (ret) {
|
155
|
-
console.debug("prepared eth call found:", key);
|
156
151
|
const result = iface
|
157
152
|
.decodeFunctionResult("totalSupply", ret)
|
158
153
|
.toArray();
|
159
154
|
return result.length == 1 ? result[0] : result;
|
160
155
|
}
|
161
|
-
console.debug("missing eth call key:", "totalSupply", key);
|
162
156
|
}
|
163
157
|
return await this.contract.getFunction("totalSupply()")(overrides || {});
|
164
158
|
} catch (e) {
|
@@ -182,14 +176,11 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
182
176
|
context: ethCallContext,
|
183
177
|
calldata,
|
184
178
|
});
|
185
|
-
console.debug("looking up eth call key:", key);
|
186
179
|
const ret = preparedData.ethCallResults[key];
|
187
180
|
if (ret) {
|
188
|
-
console.debug("prepared eth call found:", key);
|
189
181
|
const result = iface.decodeFunctionResult("decimals", ret).toArray();
|
190
182
|
return result.length == 1 ? result[0] : result;
|
191
183
|
}
|
192
|
-
console.debug("missing eth call key:", "decimals", key);
|
193
184
|
}
|
194
185
|
return await this.contract.getFunction("decimals()")(overrides || {});
|
195
186
|
} catch (e) {
|
@@ -214,14 +205,11 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
214
205
|
context: ethCallContext,
|
215
206
|
calldata,
|
216
207
|
});
|
217
|
-
console.debug("looking up eth call key:", key);
|
218
208
|
const ret = preparedData.ethCallResults[key];
|
219
209
|
if (ret) {
|
220
|
-
console.debug("prepared eth call found:", key);
|
221
210
|
const result = iface.decodeFunctionResult("balanceOf", ret).toArray();
|
222
211
|
return result.length == 1 ? result[0] : result;
|
223
212
|
}
|
224
|
-
console.debug("missing eth call key:", "balanceOf", who, key);
|
225
213
|
}
|
226
214
|
return await this.contract.getFunction("balanceOf(address)")(
|
227
215
|
who,
|
@@ -248,14 +236,11 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
248
236
|
context: ethCallContext,
|
249
237
|
calldata,
|
250
238
|
});
|
251
|
-
console.debug("looking up eth call key:", key);
|
252
239
|
const ret = preparedData.ethCallResults[key];
|
253
240
|
if (ret) {
|
254
|
-
console.debug("prepared eth call found:", key);
|
255
241
|
const result = iface.decodeFunctionResult("symbol", ret).toArray();
|
256
242
|
return result.length == 1 ? result[0] : result;
|
257
243
|
}
|
258
|
-
console.debug("missing eth call key:", "symbol", key);
|
259
244
|
}
|
260
245
|
return await this.contract.getFunction("symbol()")(overrides || {});
|
261
246
|
} catch (e) {
|
@@ -284,20 +269,11 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
284
269
|
context: ethCallContext,
|
285
270
|
calldata,
|
286
271
|
});
|
287
|
-
console.debug("looking up eth call key:", key);
|
288
272
|
const ret = preparedData.ethCallResults[key];
|
289
273
|
if (ret) {
|
290
|
-
console.debug("prepared eth call found:", key);
|
291
274
|
const result = iface.decodeFunctionResult("allowance", ret).toArray();
|
292
275
|
return result.length == 1 ? result[0] : result;
|
293
276
|
}
|
294
|
-
console.debug(
|
295
|
-
"missing eth call key:",
|
296
|
-
"allowance",
|
297
|
-
owner,
|
298
|
-
spender,
|
299
|
-
key
|
300
|
-
);
|
301
277
|
}
|
302
278
|
return await this.contract.getFunction("allowance(address,address)")(
|
303
279
|
owner,
|
@@ -333,20 +309,11 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
333
309
|
context: ethCallContext,
|
334
310
|
calldata,
|
335
311
|
});
|
336
|
-
console.debug("looking up eth call key:", key);
|
337
312
|
const ret = preparedData.ethCallResults[key];
|
338
313
|
if (ret) {
|
339
|
-
console.debug("prepared eth call found:", key);
|
340
314
|
const result = iface.decodeFunctionResult("approve", ret).toArray();
|
341
315
|
return result.length == 1 ? result[0] : result;
|
342
316
|
}
|
343
|
-
console.debug(
|
344
|
-
"missing eth call key:",
|
345
|
-
"approve",
|
346
|
-
spender,
|
347
|
-
value,
|
348
|
-
key
|
349
|
-
);
|
350
317
|
}
|
351
318
|
return await this.contract
|
352
319
|
.getFunction("approve(address,uint256)")
|
@@ -378,23 +345,13 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
378
345
|
context: ethCallContext,
|
379
346
|
calldata,
|
380
347
|
});
|
381
|
-
console.debug("looking up eth call key:", key);
|
382
348
|
const ret = preparedData.ethCallResults[key];
|
383
349
|
if (ret) {
|
384
|
-
console.debug("prepared eth call found:", key);
|
385
350
|
const result = iface
|
386
351
|
.decodeFunctionResult("transferFrom", ret)
|
387
352
|
.toArray();
|
388
353
|
return result.length == 1 ? result[0] : result;
|
389
354
|
}
|
390
|
-
console.debug(
|
391
|
-
"missing eth call key:",
|
392
|
-
"transferFrom",
|
393
|
-
from,
|
394
|
-
to,
|
395
|
-
value,
|
396
|
-
key
|
397
|
-
);
|
398
355
|
}
|
399
356
|
return await this.contract
|
400
357
|
.getFunction("transferFrom(address,address,uint256)")
|
@@ -421,16 +378,13 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
421
378
|
context: ethCallContext,
|
422
379
|
calldata,
|
423
380
|
});
|
424
|
-
console.debug("looking up eth call key:", key);
|
425
381
|
const ret = preparedData.ethCallResults[key];
|
426
382
|
if (ret) {
|
427
|
-
console.debug("prepared eth call found:", key);
|
428
383
|
const result = iface
|
429
384
|
.decodeFunctionResult("transfer", ret)
|
430
385
|
.toArray();
|
431
386
|
return result.length == 1 ? result[0] : result;
|
432
387
|
}
|
433
|
-
console.debug("missing eth call key:", "transfer", to, value, key);
|
434
388
|
}
|
435
389
|
return await this.contract
|
436
390
|
.getFunction("transfer(address,uint256)")
|