From a8a6df055384fd483ef1dc0a76cbf1cbaad33aa7 Mon Sep 17 00:00:00 2001 From: shoopea Date: Wed, 21 Aug 2019 14:53:36 +0800 Subject: [PATCH] fix compilation error --- msg.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/msg.go b/msg.go index 6cd54b1..056228f 100644 --- a/msg.go +++ b/msg.go @@ -18,7 +18,8 @@ func getMsgParsingRule(m *ChatWarsMessage) (*MessageParsingRule, error) { if i == len(msgParsingRules) { return nil, errors.New("Can't find message type in rules.") } else { - return &msgParsingRules[i], nil + r := msgParsingRules[i] + return r, nil } }