fix: push to
This commit is contained in:
@@ -82,9 +82,9 @@ class Collection(Generic[T]):
|
||||
|
||||
def _find_object(self, __object: T) -> Optional[T]:
|
||||
for c in self.push_to:
|
||||
found = c._find_object(__object)
|
||||
found, found_in = c._find_object(__object)
|
||||
if found is not None:
|
||||
return found, c
|
||||
return found, found_in
|
||||
|
||||
self._remap()
|
||||
|
||||
@@ -92,6 +92,8 @@ class Collection(Generic[T]):
|
||||
if value in self._indexed_values[name]:
|
||||
return self._indexed_values[name][value], self
|
||||
|
||||
return None, self
|
||||
|
||||
def append(self, __object: Optional[T], **kwargs):
|
||||
"""
|
||||
If an object, that represents the same entity exists in a relevant collection,
|
||||
|
Reference in New Issue
Block a user