Fix regex for URL formatting in Slack channel
This commit is contained in:
parent
5d683da38f
commit
fe0341da5b
@ -233,7 +233,7 @@ class SlackChannel(BaseChannel):
|
|||||||
# Convert URL formatting
|
# Convert URL formatting
|
||||||
# Step 6: [text](URL) -> <URL|text>
|
# Step 6: [text](URL) -> <URL|text>
|
||||||
converted_text = re.sub(
|
converted_text = re.sub(
|
||||||
r"(^|[^!])\[(.+?)\]\((http.+?)\)", r"\1<\3|\2>", converted_text)
|
r"(?m)(^|[^!])\[(.+?)\]\((http.+?)\)", r"\1<\3|\2>", converted_text)
|
||||||
# Convert image URL
|
# Convert image URL
|
||||||
# Step 6:  -> <URL>
|
# Step 6:  -> <URL>
|
||||||
converted_text = re.sub(
|
converted_text = re.sub(
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user