From ddb9d0e647d0a055731d042223f31d78b7929ed5 Mon Sep 17 00:00:00 2001 From: Sven Heidemann Date: Tue, 8 Nov 2022 20:34:47 +0100 Subject: [PATCH] Removed old code #46 --- kdb-bot/src/modules/stats/command/stats_group.py | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/kdb-bot/src/modules/stats/command/stats_group.py b/kdb-bot/src/modules/stats/command/stats_group.py index 32b32f61..01884c7a 100644 --- a/kdb-bot/src/modules/stats/command/stats_group.py +++ b/kdb-bot/src/modules/stats/command/stats_group.py @@ -95,17 +95,6 @@ class StatsGroup(DiscordCommandABC): statistic = self._stats.where(lambda s: s.name == name).single() result = await self._statistic.execute(statistic.func, server) - # headers = '' - # rows = '' - # for header in result.header: - # headers += f'\n{header}' - # - # for row in result.values: - # row_str = '' - # for column in row: - # row_str += f'\n{column}' - # rows += f'\n{row_str}' - embed = discord.Embed( title=statistic.name, description=statistic.description, @@ -119,9 +108,7 @@ class StatsGroup(DiscordCommandABC): value += f'\n{row[i]}' embed.add_field(name=header, value=value, inline=True) - # embed.add_field(name=self._t.transform('modules.auto_role.list.message_id'), value=rows, inline=True) await self._message_service.send_ctx_msg(ctx, embed, wait_before_delete=wait) - # await self._message_service.send_ctx_msg(ctx, name, wait_before_delete=wait) except Exception as e: self._logger.error(__name__, f'Cannot view statistic {name}', e) await self._message_service.send_ctx_msg(ctx, self._t.transform('modules.stats.view.failed'))