Skip to content

Commit

Permalink
Fix reputation acting on words like TYpe abd aTYpe
Browse files Browse the repository at this point in the history
  • Loading branch information
jonas747 committed Oct 7, 2017
1 parent d78c17f commit d09a17f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion reputation/plugin_bot.go
Expand Up @@ -18,7 +18,7 @@ func (p *Plugin) InitBot() {
eventsystem.AddHandler(bot.RedisWrapper(handleMessageCreate), eventsystem.EventMessageCreate)
}

var thanksRegex = regexp.MustCompile(`(?i)^(thanks?|danks|ty|thx|\+rep|\+\ ?\<\@)`)
var thanksRegex = regexp.MustCompile(`(?i)( |\n|^)(thanks?|danks|ty|thx|\+rep|\+\ ?\<\@)( |\n|$)`)

func handleMessageCreate(evt *eventsystem.EventData) {
msg := evt.MessageCreate
Expand Down

1 comment on commit d09a17f

@matmen
Copy link

@matmen matmen commented on d09a17f Nov 15, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just use \b man

Please sign in to comment.