Loading back/analysis/sentence.go +1 −1 Original line number Original line Diff line number Diff line Loading @@ -84,7 +84,7 @@ func randomizeResponse(pack plugins.Package, tag, locale string) (r bridge.Respo if len >= 1 { if len >= 1 { rand.Seed(time.Now().UnixNano()) rand.Seed(time.Now().UnixNano()) response := reponse.Messages[rand.Intn(len)] response := reponse.Messages[rand.Intn(len)] return r.Init(tag, response) return r.Init(pack.Name, response) } } } } return r.Init(DontUnderstand, util.GetMessage(locale, DontUnderstand)) return r.Init(DontUnderstand, util.GetMessage(locale, DontUnderstand)) Loading back/plugins/bridge/response.go +2 −2 Original line number Original line Diff line number Diff line Loading @@ -7,8 +7,8 @@ import ( // Response represent a Json object that will be returned by the Modules // Response represent a Json object that will be returned by the Modules type Response struct { type Response struct { Tag string `json:"tag"` Tag string `json:"package"` Response string `json:"Response"` Response string `json:"response"` Data map[string]interface{} `json:"data"` Data map[string]interface{} `json:"data"` } } Loading Loading
back/analysis/sentence.go +1 −1 Original line number Original line Diff line number Diff line Loading @@ -84,7 +84,7 @@ func randomizeResponse(pack plugins.Package, tag, locale string) (r bridge.Respo if len >= 1 { if len >= 1 { rand.Seed(time.Now().UnixNano()) rand.Seed(time.Now().UnixNano()) response := reponse.Messages[rand.Intn(len)] response := reponse.Messages[rand.Intn(len)] return r.Init(tag, response) return r.Init(pack.Name, response) } } } } return r.Init(DontUnderstand, util.GetMessage(locale, DontUnderstand)) return r.Init(DontUnderstand, util.GetMessage(locale, DontUnderstand)) Loading
back/plugins/bridge/response.go +2 −2 Original line number Original line Diff line number Diff line Loading @@ -7,8 +7,8 @@ import ( // Response represent a Json object that will be returned by the Modules // Response represent a Json object that will be returned by the Modules type Response struct { type Response struct { Tag string `json:"tag"` Tag string `json:"package"` Response string `json:"Response"` Response string `json:"response"` Data map[string]interface{} `json:"data"` Data map[string]interface{} `json:"data"` } } Loading