telethon minor fix

This commit is contained in:
msramalho
2022-06-16 14:16:18 +02:00
parent 2ac08a34f6
commit 277d81d687

View File

@@ -27,7 +27,7 @@ class TelethonArchiver(Archiver):
of `max_amp` both ways
Returns a list of [post] where each post has media and is in the same grouped_id
"""
if original_post.grouped_id is None:
if not hasattr(original_post, "grouped_id") or original_post.grouped_id is None:
return [original_post] if original_post.media is not None else []
search_ids = [i for i in range(original_post.id - max_amp, original_post.id + max_amp + 1)]