Group (code,data,log) return values into types.Result

This commit is contained in:
Jae Kwon
2016-03-20 17:10:13 -07:00
parent 29a6d511b4
commit 55e2ce9de2
6 changed files with 74 additions and 29 deletions
+6 -6
View File
@@ -19,18 +19,18 @@ func (app *NilApplication) SetOption(key string, value string) (log string) {
return ""
}
func (app *NilApplication) AppendTx(tx []byte) (code types.CodeType, result []byte, log string) {
return types.CodeType_OK, nil, ""
func (app *NilApplication) AppendTx(tx []byte) types.Result {
return types.NewResultOK(nil, "")
}
func (app *NilApplication) CheckTx(tx []byte) (code types.CodeType, result []byte, log string) {
return types.CodeType_OK, nil, ""
func (app *NilApplication) CheckTx(tx []byte) types.Result {
return types.NewResultOK(nil, "")
}
func (app *NilApplication) Commit() (hash []byte, log string) {
return []byte("nil"), ""
}
func (app *NilApplication) Query(query []byte) (code types.CodeType, result []byte, log string) {
return types.CodeType_OK, nil, ""
func (app *NilApplication) Query(query []byte) types.Result {
return types.NewResultOK(nil, "")
}