This commit is contained in:
shoopea 2019-06-06 14:17:00 +08:00
parent c943706d7a
commit b707a7c634

3
msg.go
View File

@ -1,6 +1,7 @@
package main
import (
"encoding/json"
"fmt"
"log"
"regexp"
@ -48,6 +49,8 @@ func parseSubTypeMessageAuctionAnnounce(m *ChatWarsMessage, r *regexp.Regexp) (*
cwm.Price = int32(p)
cwm.Status = r.ReplaceAllString(m.Text, "${Status}")
cwm.End, _ = fromChatWarsDate(r.ReplaceAllString(m.Text, "${End}"))
b, _ := json.Marshal(cwm)
fmt.Printf("%s\n", string(b))
return &cwm, nil
}