Update main.py
Browse files
main.py
CHANGED
@@ -51,8 +51,11 @@ async def get_user_story(link=None):
|
|
51 |
username, random_id = get_random_from_channel(link)
|
52 |
try:
|
53 |
stories = await user_client.get_stories(username, story_ids=[random_id])
|
|
|
|
|
54 |
except Exception as e:
|
55 |
return {"error": str(e)}
|
|
|
56 |
file_id = (
|
57 |
stories.photo.file_id if stories and stories.photo else None
|
58 |
or stories.video.file_id if stories and stories.video else None
|
@@ -73,6 +76,7 @@ async def get_user_story(link=None):
|
|
73 |
"selected_contacts": stories.selected_contacts,
|
74 |
"outgoing": stories.outgoing
|
75 |
}
|
|
|
76 |
|
77 |
@fast_app.get("/user/get_user")
|
78 |
async def get_user(user_id=None):
|
|
|
51 |
username, random_id = get_random_from_channel(link)
|
52 |
try:
|
53 |
stories = await user_client.get_stories(username, story_ids=[random_id])
|
54 |
+
LOGS.info(f"Updates: {stories}")
|
55 |
+
return {"done": "nothing"}
|
56 |
except Exception as e:
|
57 |
return {"error": str(e)}
|
58 |
+
""""
|
59 |
file_id = (
|
60 |
stories.photo.file_id if stories and stories.photo else None
|
61 |
or stories.video.file_id if stories and stories.video else None
|
|
|
76 |
"selected_contacts": stories.selected_contacts,
|
77 |
"outgoing": stories.outgoing
|
78 |
}
|
79 |
+
"""
|
80 |
|
81 |
@fast_app.get("/user/get_user")
|
82 |
async def get_user(user_id=None):
|