Initial Release of IGNCore version 2.5

This commit is contained in:
2021-08-09 13:18:56 +02:00
commit a83d98c47e
910 changed files with 224171 additions and 0 deletions
+18
View File
@@ -0,0 +1,18 @@
import time
from core.decorators import instance
from core.logger import Logger
@instance()
class UsageService:
def __init__(self):
self.logger = Logger(__name__)
def inject(self, registry):
self.db = registry.get_instance("db")
def add_usage(self, command, handler, char_id, channel):
self.db.exec("INSERT INTO command_usage (command, handler, char_id, channel, created_at) "
"VALUES (?, ?, ?, ?, ?)",
[command, handler, char_id, channel, int(time.time())])