From cfa79cbbaf42a8f74a2cd4bca4d1d495b4d597f1 Mon Sep 17 00:00:00 2001 From: Dmitrii Morozov Date: Tue, 7 May 2024 16:50:38 +0200 Subject: Python code style --- commands.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'commands.py') diff --git a/commands.py b/commands.py index 4cf330b..feba4b8 100644 --- a/commands.py +++ b/commands.py @@ -1,8 +1,8 @@ import telebot -from TelegramBot import * -from Formatter import * +from telegram_bot import * +from formatter import * from persistence import * -from FortniteClient import FortniteClient +from fortnite_client import FortniteClient from pythonFortniteStatus.FortniteStatus import * class StartCommand(CommandHandler): @@ -19,7 +19,7 @@ class StartCommand(CommandHandler): alias = message.chat.username else: alias = message.chat.title - self.__user_repository.putUser(message.chat.id, alias) + self.__user_repository.put_user(message.chat.id, alias) await self.__telegram_bot.reply(message, 'This chat successfully registered to receive Fortnite updates') class GetStatusCommand(CommandHandler): @@ -74,7 +74,7 @@ class GetTodayStatsCommand(CommandHandler): self.__stats_repository = stats_repository async def handle(self, message: telebot.types.Message): - persisted_stats = self.__stats_repository.getStats() + persisted_stats = self.__stats_repository.get_stats() friends = await self.__fortnite_client.get_friends() current_stats = [await friend.fetch_stats() for friend in friends] await self.__telegram_bot.reply(message, format_user_stats_difference(persisted_stats, current_stats)) @@ -91,4 +91,4 @@ class RecordStatsCommand(CommandHandler): async def handle(self, message: telebot.types.Message): friends = await self.__fortnite_client.get_friends() for friend in friends: - await self.__stats_repository.putStats(friend) \ No newline at end of file + await self.__stats_repository.put_stats(friend) \ No newline at end of file -- cgit v1.2.3