Skip to content

Commit e299f6c

Browse files
authored
Add support for ethereum.getCode (#1609)
* Add `getCode` method to ethereum API * Add changeset
1 parent 66999b1 commit e299f6c

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

.changeset/hip-nails-double.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@graphprotocol/graph-ts': minor
3+
---
4+
5+
Add support for eth.hasCode method

packages/ts/chain/ethereum.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import { Address, BigInt } from '../common/numbers';
66
export declare namespace ethereum {
77
function call(call: SmartContractCall): Array<Value> | null;
88
function getBalance(address: Address): BigInt;
9+
function hasCode(address: Address): bool;
910
function encode(token: Value): Bytes | null;
1011
function decode(types: String, data: Bytes): Value | null;
1112
}

0 commit comments

Comments
 (0)