From d600205fdbd59eb652d2f4bd344ac93552a9b52f Mon Sep 17 00:00:00 2001 From: yaziming Date: Wed, 3 Jun 2020 18:58:33 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E9=94=99=E8=AF=AF=E7=9A=84?= =?UTF-8?q?=E5=8F=98=E9=87=8F=E5=A3=B0=E6=98=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/routes/spider.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/routes/spider.go b/backend/routes/spider.go index 3363ec9f..e7faf051 100644 --- a/backend/routes/spider.go +++ b/backend/routes/spider.go @@ -567,7 +567,7 @@ func UploadSpiderFromId(c *gin.Context) { // TODO: 与 UploadSpider 部分逻辑重复,需要优化代码 // 爬虫ID spiderId := c.Param("id") - if !bson.IsObjectIdHex(id) { + if !bson.IsObjectIdHex(spiderId) { HandleErrorF(http.StatusBadRequest, c, "invalid id") return }