From 27956b5ebe6529d3447a7340096ccfbd801f7868 Mon Sep 17 00:00:00 2001 From: Alter-xyz <88554920+alterxyz@users.noreply.github.com> Date: Wed, 24 Jul 2024 18:39:41 -0400 Subject: [PATCH] Update tweet.py --- handlers/tweet.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/handlers/tweet.py b/handlers/tweet.py index 4b4515b..0f1745f 100644 --- a/handlers/tweet.py +++ b/handlers/tweet.py @@ -16,7 +16,9 @@ def tweet_handler(message: Message, bot: TeleBot): if links: reply_id = bot_reply_first(message, who, bot) processed_links = [ - link.replace("twitter.com", "fxtwitter.com").replace("x.com", "fixupx.com") + link.replace("https://twitter.com", "https://fxtwitter.com").replace( + "https://x.com", "https://fixupx.com" + ) for link in links ] bot_reply_markdown(reply_id, who, "\n".join(processed_links), bot)