From: Edward Delaporte Date: Mon, 8 Jun 2026 03:19:05 +0000 (-0500) Subject: Fix for spammy list output X-Git-Url: https://apps.delaporte.us/gitweb/matrix-fridge-bot.git/commitdiff_plain/a04196abe4b5942897db75366398c437187ea000?ds=inline Fix for spammy list output --- diff --git a/matrix_fridge_bot/bot.py b/matrix_fridge_bot/bot.py index 14767f3..90971cf 100644 --- a/matrix_fridge_bot/bot.py +++ b/matrix_fridge_bot/bot.py @@ -52,10 +52,17 @@ class FridgeBot(): if match.prefix(): try: result_lines = await self._handle_match(match) + + message_lines = [] for line in result_lines: - await self.bot.api.send_text_message( - room.room_id, str(line)) - except Exception as ex: + message_lines.append(str(line)) + + message = '\n'.join(message_lines) + + await self.bot.api.send_text_message( + room.room_id, message) + + except Exception as ex: line = f'Ye flask must be load bearing, or something... {str(ex)}' await self.bot.api.send_text_message( room.room_id, str(line))