mattmakai / slack-starterbot

Python-powered simple starter Slack bot.
https://www.fullstackpython.com/blog/build-first-slack-bot-python.html
MIT License
197 stars 146 forks source link

Minor regex issue #8

Open fl0g opened 6 years ago

fl0g commented 6 years ago

The regex for direct mention will fail if another user is mention in the message. I.e. regex <@([WU].+)>.+ will match "<@Uuser1> message <@Uuser2> more message" to the last ">" in the string. Suggest to change to <@([WU].+?)>.+

Encountered this when I wanted the bot parse commands to interact with other users.