fix bal jsonrpc method naming to comply with the spec

This commit is contained in:
Jared Wasinger 2026-02-03 14:16:41 -05:00 committed by MariusVanDerWijden
parent a780983dfa
commit 206eb81148
2 changed files with 6 additions and 6 deletions

View file

@ -1342,15 +1342,15 @@ func AccessList(ctx context.Context, b Backend, blockNrOrHash rpc.BlockNumberOrH
}
}
// BlockAccessListByBlockNumber returns a block access list for the given block number
// GetBlockAccessListByBlockNumber returns a block access list for the given block number
// or nil if one does not exist.
func (api *BlockChainAPI) BlockAccessListByBlockNumber(number rpc.BlockNumber) (interface{}, error) {
func (api *BlockChainAPI) GetBlockAccessListByBlockNumber(number rpc.BlockNumber) (interface{}, error) {
return api.b.BlockAccessListByNumberOrHash(rpc.BlockNumberOrHash{BlockNumber: &number})
}
// BlockAccessListByBlockHash returns a block access list for the given block hash
// GetBlockAccessListByBlockHash returns a block access list for the given block hash
// or nil if one does not exist.
func (api *BlockChainAPI) BlockAccessListByBlockHash(hash common.Hash) (interface{}, error) {
func (api *BlockChainAPI) GetBlockAccessListByBlockHash(hash common.Hash) (interface{}, error) {
return api.b.BlockAccessListByNumberOrHash(rpc.BlockNumberOrHash{BlockHash: &hash})
}

View file

@ -613,12 +613,12 @@ web3._extend({
}),
new web3._extend.Method({
name: 'getBlockAccessListByBlockNumber',
call: 'eth_blockAccessListByBlockNumber',
call: 'eth_getBlockAccessListByBlockNumber',
params: 1,
}),
new web3._extend.Method({
name: 'getBlockAccessListByBlockHash',
call: 'eth_blockAccessListByBlockHash',
call: 'eth_getBlockAccessListByBlockHash',
params: 1,
}),
],