This commit is contained in:
shoopea 2019-12-29 16:40:36 +08:00
parent 7410c9dcd3
commit c3c70fcdd7

View File

@ -5,7 +5,7 @@ import (
)
func resetMsgParsingRules2() error {
var rules
var rules []MessageParsingRule{}
_, err := db.Exec(`TRUNCATE TABLE msg_rules;`)
logOnError(err, "resetMsgParsingRules2 : truncate table msg_rules")
if err != nil {
@ -18,7 +18,6 @@ func resetMsgParsingRules2() error {
return err
}
rules := []MessageParsingRule{}
err = json.Unmarshal(b, &rules)
return nil