diff options
-rw-r--r-- | poezio/mam.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/poezio/mam.py b/poezio/mam.py index 5bc33a4c..f4adc135 100644 --- a/poezio/mam.py +++ b/poezio/mam.py @@ -133,6 +133,12 @@ def mam_scroll(tab): except: before = None end = datetime.now() + if isinstance(tab, tabs.MucTab) is False: + for message in text_buffer.messages: + time = message.time + if time < end: + end = time + end = end + timedelta(seconds=-1) tzone = datetime.now().astimezone().tzinfo end = end.replace(tzinfo=tzone).astimezone(tz=timezone.utc) end = end.replace(tzinfo=None) |