Expose state trie to plugins
Also merged changes in support geth v1.11.6. Updated to plugeth-utils v1.1.0.
This commit is contained in:
@@ -476,7 +476,7 @@ func (b *Backend) GetAccountTrie(stateRoot core.Hash, account core.Address) (cor
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
act, err := tr.TryGetAccount(account)
|
||||
act, err := tr.GetAccount(account)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
@@ -19,12 +19,9 @@ func NewWrappedTrie(t state.Trie) core.Trie {
|
||||
func (t *WrappedTrie) GetKey(b []byte) []byte {
|
||||
return t.t.GetKey(b)
|
||||
}
|
||||
func (t *WrappedTrie) TryGet(key []byte) ([]byte, error) {
|
||||
return t.t.TryGet(key)
|
||||
}
|
||||
|
||||
func (t *WrappedTrie) TryGetAccount(address core.Address) (*core.StateAccount, error) {
|
||||
act, err := t.t.TryGetAccount(common.Address(address))
|
||||
func (t *WrappedTrie) GetAccount(address core.Address) (*core.StateAccount, error) {
|
||||
act, err := t.t.GetAccount(common.Address(address))
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user