Update functions that return error to not return pointer

* Matches Golang convention
This commit is contained in:
Eric Meyer
2017-12-04 10:34:49 -06:00
parent f46891f732
commit 486fdc10e4
7 changed files with 24 additions and 24 deletions
+3 -3
View File
@@ -57,11 +57,11 @@ func (blockchain *GethBlockchain) getContractAttributes(contractHash string) (co
return contractAttributes, nil
}
func bindContract(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor) (*bind.BoundContract, error) {
func bindContract(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor) (bind.BoundContract, error) {
abiFilePath := filepath.Join(config.ProjectRoot(), "contracts", "public", fmt.Sprintf("%s.json", address.Hex()))
parsed, err := ParseAbiFile(abiFilePath)
if err != nil {
return nil, err
return bind.BoundContract{}, err
}
return bind.NewBoundContract(address, parsed, caller, transactor), nil
return *bind.NewBoundContract(address, parsed, caller, transactor), nil
}