Spaces:
Running
Running
Update FileStream/bot/plugins/FileHandlers/callback.py
Browse files
FileStream/bot/plugins/FileHandlers/callback.py
CHANGED
@@ -138,15 +138,15 @@ async def cb_data(bot: Client, update: CallbackQuery):
|
|
138 |
)
|
139 |
|
140 |
elif usr_cmd[0] == "pubup":
|
141 |
-
print("Public Upload :", usr_cmd)
|
142 |
-
user_id = str(usr_cmd[1])
|
143 |
-
message_id = int(usr_cmd[2])
|
144 |
-
message = await FileStream.get_messages(user_id, message_id)
|
145 |
-
#response = await FileStream.get_messages(user_id, response_id)
|
146 |
-
name = getattr(message, "caption", f"{get_name(message)}" ) or "None/Unknown"
|
147 |
-
#file_name = get_name(message)
|
148 |
-
#name = file_caption if (file_caption) != "None/Unknown" else file_name
|
149 |
try:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
150 |
print(f"User:{user_id}","FileName :", name)
|
151 |
title, year = Get_Title_Year(name)
|
152 |
print(f"** ANY SEARCH :{name} \nFinal :{title} YEAR :{year}")
|
|
|
138 |
)
|
139 |
|
140 |
elif usr_cmd[0] == "pubup":
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
141 |
try:
|
142 |
+
print("Public Upload :", usr_cmd)
|
143 |
+
user_id = str(usr_cmd[1])
|
144 |
+
message_id = int(usr_cmd[2])
|
145 |
+
message = await FileStream.get_messages(user_id, message_id)
|
146 |
+
#response = await FileStream.get_messages(user_id, response_id)
|
147 |
+
name = getattr(message, "caption", f"{get_name(message)}" ) or "None/Unknown"
|
148 |
+
#file_name = get_name(message)
|
149 |
+
#name = file_caption if (file_caption) != "None/Unknown" else file_name
|
150 |
print(f"User:{user_id}","FileName :", name)
|
151 |
title, year = Get_Title_Year(name)
|
152 |
print(f"** ANY SEARCH :{name} \nFinal :{title} YEAR :{year}")
|