We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e3b0c76 commit 53e6159Copy full SHA for 53e6159
pkg/gmc/handler/bot.go
@@ -59,6 +59,10 @@ func CreateBot(c *gin.Context) {
59
c.String(http.StatusBadRequest, "bad request, not protobuf")
60
return
61
}
62
+ if req.BotId == 0 {
63
+ c.String(http.StatusBadRequest, "botId is 0")
64
+ return
65
+ }
66
_, ok := bot.Clients[req.BotId]
67
if ok {
68
c.String(http.StatusInternalServerError, "botId already exists")
0 commit comments