Fix go lint issue

Fix go lint issue by running goimports.

Signed-off-by: David Enyeart <enyeart@us.ibm.com>
This commit is contained in:
David Enyeart 2023-03-01 12:10:08 -05:00 committed by Dave Enyeart
parent f7b3a7703f
commit 128950edca

View file

@ -77,19 +77,19 @@ func main() {
func exampleTransaction(gateway *client.Gateway) { func exampleTransaction(gateway *client.Gateway) {
// Override default values for chaincode and channel name as they may differ in testing contexts. // Override default values for chaincode and channel name as they may differ in testing contexts.
channelName := "mychannel" channelName := "mychannel"
if cname := os.Getenv("CHANNEL_NAME"); cname != "" { if cname := os.Getenv("CHANNEL_NAME"); cname != "" {
channelName = cname channelName = cname
} }
chaincodeName := "basic" chaincodeName := "basic"
if ccname := os.Getenv("CHAINCODE_NAME"); ccname != "" { if ccname := os.Getenv("CHAINCODE_NAME"); ccname != "" {
chaincodeName = ccname chaincodeName = ccname
} }
network := gateway.GetNetwork(channelName) network := gateway.GetNetwork(channelName)
contract := network.GetContract(chaincodeName) contract := network.GetContract(chaincodeName)
fmt.Printf("Submit Transaction: CreateAsset, creates new asset with ID, Color, Size, Owner and AppraisedValue arguments \n") fmt.Printf("Submit Transaction: CreateAsset, creates new asset with ID, Color, Size, Owner and AppraisedValue arguments \n")