Fix regex for URL formatting in Slack channel

This commit is contained in:
Aleksander W. Oleszkiewicz (Alek) 2026-02-16 09:58:38 +01:00 committed by GitHub
parent 5d683da38f
commit fe0341da5b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -233,7 +233,7 @@ class SlackChannel(BaseChannel):
# Convert URL formatting
# Step 6: [text](URL) -> <URL|text>
converted_text = re.sub(
r"(^|[^!])\[(.+?)\]\((http.+?)\)", r"\1<\3|\2>", converted_text)
r"(?m)(^|[^!])\[(.+?)\]\((http.+?)\)", r"\1<\3|\2>", converted_text)
# Convert image URL
# Step 6: ![alt text](URL "title") -> <URL>
converted_text = re.sub(