Skip to content

Commit

Permalink
replace usage of address.Address{} with address.Undef
Browse files Browse the repository at this point in the history
  • Loading branch information
frrist committed Mar 15, 2019
1 parent cdf1831 commit ca1113d
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion abi/abi.go
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ func (av *Value) Serialize() ([]byte, error) {
case Address:
addr, ok := av.Val.(address.Address)
if !ok {
return nil, &typeError{address.Address{}, av.Val}
return nil, &typeError{address.Undef, av.Val}
}
return addr.Bytes(), nil
case AttoFIL:
Expand Down
4 changes: 2 additions & 2 deletions porcelain/message.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,11 @@ func GetAndMaybeSetDefaultSenderAddress(plumbing gamsdsaAPI) (address.Address, e
addr := plumbing.WalletAddresses()[0]
err := plumbing.ConfigSet("wallet.defaultAddress", addr.String())
if err != nil {
return address.Address{}, err
return address.Undef, err
}

return addr, nil
}

return address.Address{}, ErrNoDefaultFromAddress
return address.Undef, ErrNoDefaultFromAddress
}
2 changes: 1 addition & 1 deletion porcelain/miner.go
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ func MinerGetOwnerAddress(ctx context.Context, plumbing mgoaAPI, minerAddr addre

// MinerGetKey queries for the public key of the given miner
func MinerGetKey(ctx context.Context, plumbing mgoaAPI, minerAddr address.Address) ([]byte, error) {
res, _, err := plumbing.MessageQuery(ctx, address.Address{}, minerAddr, "getKey")
res, _, err := plumbing.MessageQuery(ctx, address.Undef, minerAddr, "getKey")
if err != nil {
return []byte{}, err
}
Expand Down
2 changes: 1 addition & 1 deletion testhelpers/consensus.go
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ func applyTestMessageWithAncestors(st state.Tree, store vm.StorageMap, msg *type
}

ta := newTestApplier()
return newMessageApplier(smsg, ta, st, store, bh, address.Address{}, ancestors)
return newMessageApplier(smsg, ta, st, store, bh, address.Undef, ancestors)
}

func newTestApplier() *consensus.DefaultProcessor {
Expand Down

0 comments on commit ca1113d

Please sign in to comment.