mirror of
https://github.com/aljazceru/chatgpt-telegram-bot.git
synced 2025-12-22 15:14:54 +01:00
move utils funcs to standalone file
This commit is contained in:
@@ -175,6 +175,9 @@ class UsageTracker:
|
||||
json.dump(self.usage, outfile)
|
||||
|
||||
def add_current_costs(self, request_cost):
|
||||
"""
|
||||
Add current cost to all_time, day and month cost and update last_update date.
|
||||
"""
|
||||
today = date.today()
|
||||
last_update = date.fromisoformat(self.usage["current_cost"]["last_update"])
|
||||
|
||||
|
||||
Reference in New Issue
Block a user