소스 검색

fix go vet

wenzl 7 년 전
부모
커밋
4207d369b3
3개의 변경된 파일3개의 추가작업 그리고 3개의 파일을 삭제
  1. 1 1
      examples/beego/beego.go
  2. 1 1
      examples/gin/gin.go
  3. 1 1
      examples/http/http.go

+ 1 - 1
examples/beego/beego.go

@@ -26,7 +26,7 @@ func hello(ctx *context.Context) {
 
 		//回复消息:演示回复用户发送的消息
 		text := message.NewText(msg.Content)
-		return &message.Reply{message.MsgTypeText, text}
+		return &message.Reply{MsgType: message.MsgTypeText, MsgData: text}
 	})
 
 	//处理消息接收以及回复

+ 1 - 1
examples/gin/gin.go

@@ -33,7 +33,7 @@ func hello(c *gin.Context) {
 
 		//回复消息:演示回复用户发送的消息
 		text := message.NewText(msg.Content)
-		return &message.Reply{message.MsgTypeText, text}
+		return &message.Reply{MsgType: message.MsgTypeText, MsgData: text}
 	})
 
 	//处理消息接收以及回复

+ 1 - 1
examples/http/http.go

@@ -26,7 +26,7 @@ func hello(rw http.ResponseWriter, req *http.Request) {
 
 		//回复消息:演示回复用户发送的消息
 		text := message.NewText(msg.Content)
-		return &message.Reply{message.MsgTypeText, text}
+		return &message.Reply{MsgType: message.MsgTypeText, MsgData: text}
 	})
 
 	//处理消息接收以及回复