Browse Source

:bug: stuct 类型错误

visuddhinanda 4 years ago
parent
commit
3f9b00c3c9
1 changed files with 1 additions and 1 deletions
  1. 1 1
      api/mint/article.go

+ 1 - 1
api/mint/article.go

@@ -112,7 +112,7 @@ func PutArticle(db *pg.DB) gin.HandlerFunc{
 //改
 func PostAritcle(db *pg.DB) gin.HandlerFunc{
 	return func(c *gin.Context){
-		var form Lesson
+		var form Article
 
 		if err := c.ShouldBindJSON(&form); err != nil {
 			c.JSON(http.StatusBadRequest, gin.H{"error": err.Error()})