From 0f88641eddbeb6a2e4c863421d92e14c2b9bc098 Mon Sep 17 00:00:00 2001 From: dgw Date: Sun, 8 Aug 2021 00:08:03 -0700 Subject: [PATCH] Merge pull request #2163 from sopel-irc/reddit-post-link-query reddit: don't anchor to end of post links Cherry-picked from master: aac60eae0992f27acdd4d7f61be852e5e083a364 --- sopel/modules/reddit.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sopel/modules/reddit.py b/sopel/modules/reddit.py index 5f53908d43..94d06c31ce 100644 --- a/sopel/modules/reddit.py +++ b/sopel/modules/reddit.py @@ -39,7 +39,7 @@ domain = r'https?://(?:www\.|old\.|pay\.|ssl\.|[a-z]{2}\.)?reddit\.com' subreddit_url = r'%s/r/([\w-]+)/?$' % domain -post_url = r'%s/r/\S+?/comments/([\w-]+)(?:/[\w%%]+)?/?$' % domain +post_url = r'%s/r/\S+?/comments/([\w-]+)(?:/[\w%%]+)?/?' % domain short_post_url = r'https?://redd\.it/([\w-]+)' user_url = r'%s/u(?:ser)?/([\w-]+)' % domain comment_url = r'%s/r/\S+?/comments/\S+?/\S+?/([\w-]+)' % domain