remove line msg to es

This commit is contained in:
Jay 2018-10-12 16:22:00 +08:00
parent 08ae3289ee
commit 0b8aeee181

View File

@ -7,8 +7,6 @@ import (
"encoding/json" "encoding/json"
"io/ioutil" "io/ioutil"
"git.trj.tw/golang/mtfosbot/module/es"
"git.trj.tw/golang/mtfosbot/module/config" "git.trj.tw/golang/mtfosbot/module/config"
"git.trj.tw/golang/mtfosbot/module/context" "git.trj.tw/golang/mtfosbot/module/context"
"git.trj.tw/golang/mtfosbot/module/line-message" "git.trj.tw/golang/mtfosbot/module/line-message"
@ -73,14 +71,6 @@ func GetLineMessage(c *context.Context) {
c.DataFormat("body type error") c.DataFormat("body type error")
} }
jsonMap := make(map[string]interface{})
if err := json.Unmarshal(raw, &jsonMap); err == nil {
es.PutLog("line", jsonMap)
}
defer func() {
jsonMap = nil
}()
events := struct { events := struct {
Events []*lineobj.EventObject `json:"events"` Events []*lineobj.EventObject `json:"events"`
}{} }{}