mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 18:32:23 +00:00
core/state: suggestion from martin
This commit is contained in:
parent
5005f215ac
commit
1d84edd2fe
1 changed files with 3 additions and 3 deletions
|
|
@ -150,10 +150,10 @@ func (s *stateObject) GetState(key common.Hash) common.Hash {
|
|||
func (s *stateObject) getState(key common.Hash) (common.Hash, common.Hash) {
|
||||
origin := s.GetCommittedState(key)
|
||||
value, dirty := s.dirtyStorage[key]
|
||||
if !dirty {
|
||||
value = origin
|
||||
if dirty {
|
||||
return value, origin
|
||||
}
|
||||
return value, origin
|
||||
return origin, origin
|
||||
}
|
||||
|
||||
// GetCommittedState retrieves a value from the committed account storage trie.
|
||||
|
|
|
|||
Loading…
Reference in a new issue