This commit is contained in:
shoopea 2020-02-03 12:07:39 +08:00
parent 58d46f6d46
commit 6c1a99870a

2
msg.go
View File

@ -277,7 +277,7 @@ func parseSubTypeMessageGStockAnyAck(m *ChatWarsMessage, r *regexp.Regexp) (*Cha
func parseSubTypeMessageTributesStatsAck(m *ChatWarsMessage, r *regexp.Regexp) (*ChatWarsMessageTributesStatsAck, error) {
cwm := ChatWarsMessageTributesStatsAck{}
tribute := []ChatWarsTribute{}
tribute := ChatWarsTribute{}
re := regexp.MustCompile(`((?P<Date>[1-9]{2} [a-zA-Z]+ [0-9]{4} [0-9]{2}:[0-9]{2}) - (?P<Item>[a-zA-Z]+) x (?P<Quantity>[0-9]+), (?P<Exp>[0-9]+)🔥(\n){0,1})`)
for _, l := range re.FindAllStringSubmatch(m.Text, -1) {
log.Printf("parseSubTypeMessageTributesStatsAck : Date : %s\n", r.ReplaceAllString(l[0], "${Date}"))