Skip to content
This repository was archived by the owner on Feb 9, 2021. It is now read-only.

Commit f92acb3

Browse files
committed
Import release v0.8.1
This is a legacy import of the release originally managed in pure github. You may find the history of this release in the archives here: https://github.com/hyperledger-archives/fabric-chaintool/releases/tag/v0.8.1 Change-Id: I2b10603e4dcc5dfecaedc2c6c1252324516d6247 Signed-off-by: Gregory Haskins <gregory.haskins@gmail.com>
1 parent 20eadfd commit f92acb3

File tree

3 files changed

+8
-4
lines changed

3 files changed

+8
-4
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,5 @@ pom.xml
1010
.lein-plugins
1111
.idea
1212
*.iml
13+
**/node_modules
14+
**/out

project.clj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
(defproject chaintool "0.8.0"
1+
(defproject chaintool "0.8.1"
22
:description "hyperledger chaincode tool"
33
:url "https://github.com/ghaskins/chaintool"
44
:license {:name "Apache License"

resources/generators/golang.stg

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -365,16 +365,18 @@ implementhandler(txn) ::=
365365
<<
366366
func (self *stubHandler) <if(txn)>Invoke<else>Query<endif>(stub *shim.ChaincodeStub, function string, args []string) ([]byte, error) {
367367

368-
if len(args) != 1 {
369-
return nil, errors.New("Expected exactly one argument")
368+
var params string;
369+
370+
if len(args) > 0 {
371+
params = args[0]
370372
}
371373

372374
dispatcher, index, err := self.decodeFunction(<if(txn)>txnre<else>queryre<endif>, function)
373375
if err != nil {
374376
return nil, err
375377
}
376378

377-
return dispatcher.Dispatch<if(txn)>Txn<else>Query<endif>(stub, index, args[0])
379+
return dispatcher.Dispatch<if(txn)>Txn<else>Query<endif>(stub, index, params)
378380
}
379381
>>
380382

0 commit comments

Comments
 (0)