mirror of
https://github.com/Xtao-Labs/iShotaBot.git
synced 2024-11-23 08:20:55 +00:00
chore: update bsky domain
This commit is contained in:
parent
e729d6e93d
commit
966acd108e
@ -59,7 +59,9 @@ class Timeline:
|
||||
)
|
||||
|
||||
@staticmethod
|
||||
def get_media_group(text: str, post: HumanPost, has_spoiler: bool) -> list[InputMediaPhoto]:
|
||||
def get_media_group(
|
||||
text: str, post: HumanPost, has_spoiler: bool
|
||||
) -> list[InputMediaPhoto]:
|
||||
data = []
|
||||
images = post.images
|
||||
for idx, image in enumerate(images):
|
||||
|
@ -18,7 +18,7 @@ class Reply(BaseModel):
|
||||
|
||||
async def process_url(url: str, reply: Reply, override_hidden: bool):
|
||||
url = urlparse(url)
|
||||
if url.hostname and url.hostname in ["bsky.app"]:
|
||||
if url.hostname and url.hostname in ["bsky.app", "bsky.xtaolabs.com"]:
|
||||
if url.path.find("profile") < 0:
|
||||
return
|
||||
author_handle = str(url.path[url.path.find("profile") + 8 :].split("/")[0])
|
||||
@ -40,7 +40,7 @@ async def process_url(url: str, reply: Reply, override_hidden: bool):
|
||||
print(e)
|
||||
|
||||
|
||||
@bot.on_message(filters.incoming & filters.text & filters.regex(r"bsky.app/"))
|
||||
@bot.on_message(filters.incoming & filters.text & filters.regex(r"bsky.*?\/profile\/"))
|
||||
async def bsky_share(_: Client, message: Message):
|
||||
text = message.text
|
||||
if not text:
|
||||
|
Loading…
Reference in New Issue
Block a user