refactor: cleaned main file

This commit is contained in:
2025-10-31 11:29:24 +04:00
parent 36b3e056dc
commit ef657c4939
8 changed files with 84 additions and 53 deletions

7
utils/singleton.py Normal file
View File

@ -0,0 +1,7 @@
class Singleton(type):
_instances = {}
def __call__(cls, *args, **kwargs):
if cls not in cls._instances:
cls._instances[cls] = super(Singleton, cls).__call__(*args, **kwargs)
return cls._instances[cls]