test
This commit is contained in:
parent
5c7da6e1d2
commit
546f9bcdfe
4
bot.go
4
bot.go
@ -212,7 +212,7 @@ func botListParsingRules(m *tb.Message) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
for v, _ := range msgParsingRules {
|
for _, v := range msgParsingRules {
|
||||||
s := fmt.Sprintf("[%d] %s\n", v.ID, v.Descn)
|
s := fmt.Sprintf("[%d] %s\n", v.ID, v.Descn)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -230,7 +230,7 @@ func botListParsingRule(m *tb.Message) {
|
|||||||
r := regexp.MustCompile("^[0-9]+$")
|
r := regexp.MustCompile("^[0-9]+$")
|
||||||
if r.MatchString(m.Payload) {
|
if r.MatchString(m.Payload) {
|
||||||
i, _ := strconv.ParseInt(m.Payload, 10, 64)
|
i, _ := strconv.ParseInt(m.Payload, 10, 64)
|
||||||
for v, _ := range msgParsingRules {
|
for _, v := range msgParsingRules {
|
||||||
if v.ID == i {
|
if v.ID == i {
|
||||||
c := TGCommand{
|
c := TGCommand{
|
||||||
Type: commandReplyMsg,
|
Type: commandReplyMsg,
|
||||||
|
Loading…
Reference in New Issue
Block a user