Skip to content

Commit 47311c5

Browse files
removes useless collection setter
1 parent 910f2ba commit 47311c5

1 file changed

Lines changed: 2 additions & 8 deletions

File tree

lib/repositories/repo.py

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@ def __new__(cls, *args, **kwargs):
2121
cls._instances[cls] = instance
2222
return cls._instances[cls]
2323

24-
def __init__(self, collection: str):
24+
def __init__(self, collection_name: str):
2525
if not getattr(self, '_initialized', False):
26-
self._collection_name = collection
26+
self._collection_name = collection_name
2727
self._initialized_event = asyncio.Event()
2828
if not asyncio.get_event_loop().is_running():
2929
asyncio.run(self._async_init())
@@ -108,9 +108,3 @@ def collection(self):
108108
if not getattr(self, '_initialized', False):
109109
raise RuntimeError("Repository not initialized yet")
110110
return self._collection
111-
112-
@collection.setter
113-
def collection(self, value):
114-
if not getattr(self, '_initialized', False):
115-
raise RuntimeError("Repository not initialized yet")
116-
self._collection = value

0 commit comments

Comments
 (0)