Removed leftover folder

This commit is contained in:
Pratyush Shukla
2023-10-03 04:08:23 +05:30
parent c3b9cb090e
commit 2a152ae81b

View File

@@ -1,15 +0,0 @@
from typing import Dict, Generic, TypeVar
T = TypeVar("T")
class SingletonMeta(type, Generic[T]):
# TODO : check if we want to update this to be thread safe
_instances: Dict[T, T] = {}
def __call__(cls, *args, **kwargs):
if cls not in cls._instances:
instance = super().__call__(*args, **kwargs)
cls._instances[cls] = instance
return cls._instances[cls]