mirror of
https://github.com/hyperledger/fabric-samples.git
synced 2026-06-17 15:35:09 +00:00
Fix unmarshaling asset in ReadAsset()
Signed-off-by: Tiffany Harris <tiffany.harris@ibm.com>
This commit is contained in:
parent
12b07b40a9
commit
cad6b90383
2 changed files with 2 additions and 1 deletions
|
|
@ -38,7 +38,7 @@ func (s *SmartContract) ReadAsset(ctx contractapi.TransactionContextInterface, a
|
||||||
}
|
}
|
||||||
|
|
||||||
var asset *Asset
|
var asset *Asset
|
||||||
err = json.Unmarshal(assetJSON, asset)
|
err = json.Unmarshal(assetJSON, &asset)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@ module github.com/hyperledger/fabric-samples/chaincode/tradingMarbles
|
||||||
go 1.14
|
go 1.14
|
||||||
|
|
||||||
require (
|
require (
|
||||||
|
github.com/golang/protobuf v1.3.2
|
||||||
github.com/hyperledger/fabric-chaincode-go v0.0.0-20200128192331-2d899240a7ed
|
github.com/hyperledger/fabric-chaincode-go v0.0.0-20200128192331-2d899240a7ed
|
||||||
github.com/hyperledger/fabric-contract-api-go v1.0.0
|
github.com/hyperledger/fabric-contract-api-go v1.0.0
|
||||||
)
|
)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue