Spaces:
Sleeping
Sleeping
Captain Ezio
commited on
Commit
·
eb6d43b
1
Parent(s):
c15d499
Looks good
Browse files- Powers/plugins/pin.py +2 -6
Powers/plugins/pin.py
CHANGED
@@ -30,15 +30,11 @@ async def pin_message(_, m: Message):
|
|
30 |
if m.chat.username:
|
31 |
# If chat has a username, use this format
|
32 |
link_chat_id = m.chat.username
|
33 |
-
message_link =
|
34 |
-
f"https://t.me/{link_chat_id}/{m.reply_to_message.id}"
|
35 |
-
)
|
36 |
elif (str(m.chat.id)).startswith("-100"):
|
37 |
# If chat does not have a username, use this
|
38 |
link_chat_id = (str(m.chat.id)).replace("-100", "")
|
39 |
-
message_link =
|
40 |
-
f"https://t.me/c/{link_chat_id}/{m.reply_to_message.id}"
|
41 |
-
)
|
42 |
await m.reply_text(
|
43 |
text=f"I have Pinned [this message]({message_link})!",
|
44 |
disable_web_page_preview=True,
|
|
|
30 |
if m.chat.username:
|
31 |
# If chat has a username, use this format
|
32 |
link_chat_id = m.chat.username
|
33 |
+
message_link = f"https://t.me/{link_chat_id}/{m.reply_to_message.id}"
|
|
|
|
|
34 |
elif (str(m.chat.id)).startswith("-100"):
|
35 |
# If chat does not have a username, use this
|
36 |
link_chat_id = (str(m.chat.id)).replace("-100", "")
|
37 |
+
message_link = f"https://t.me/c/{link_chat_id}/{m.reply_to_message.id}"
|
|
|
|
|
38 |
await m.reply_text(
|
39 |
text=f"I have Pinned [this message]({message_link})!",
|
40 |
disable_web_page_preview=True,
|