Skip to content

Commit

Permalink
include missing key in error message
Browse files Browse the repository at this point in the history
  • Loading branch information
zhangchiqing committed Nov 27, 2024
1 parent 59a1d05 commit 2ff3bee
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions fvm/evm/emulator/state/base.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,13 +74,13 @@ func NewBaseView(ledger atree.Ledger, rootAddress flow.Address) (*BaseView, erro
// fetch the account collection, if not exist, create one
view.accounts, view.accountSetupOnCommit, err = view.fetchOrCreateCollection(AccountsStorageIDKey)
if err != nil {
return nil, err
return nil, fmt.Errorf("failed to fetch or create account collection with key %v: %w", AccountsStorageIDKey, err)
}

// fetch the code collection, if not exist, create one
view.codes, view.codeSetupOnCommit, err = view.fetchOrCreateCollection(CodesStorageIDKey)
if err != nil {
return nil, err
return nil, fmt.Errorf("failed to fetch or create code collection with key %v: %w", CodesStorageIDKey, err)
}

return view, nil
Expand Down

0 comments on commit 2ff3bee

Please sign in to comment.