From 254d723ecf69e966b25023cec75ab520dbc7399e Mon Sep 17 00:00:00 2001 From: Steve McCoy Date: Thu, 30 Aug 2018 14:14:52 -0400 Subject: [PATCH] I had parsing on the brain, I swear --- plugins/picker/picker.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/picker/picker.go b/plugins/picker/picker.go index 5853348..1b6a16d 100644 --- a/plugins/picker/picker.go +++ b/plugins/picker/picker.go @@ -57,8 +57,8 @@ func (p *PickerPlugin) Message(message msg.Message) bool { return true } -var pickerListPrologue = regexp.MustParse(`^pick[ \t]+([0-9]*)[ \t]+\{[ \t]+`) -var pickerListItem = regexp.MustParse(`^([^,]+),[ \t]+`) +var pickerListPrologue = regexp.MustCompile(`^pick[ \t]+([0-9]*)[ \t]+\{[ \t]+`) +var pickerListItem = regexp.MustCompile(`^([^,]+),[ \t]+`) func (p * PickerPlugin) parse(body string) (int, []string, error) { subs := pickerListPrologue.FindStringSubmatch(body)