Skip to content

Commit

Permalink
fixes memory leak (#1523)
Browse files Browse the repository at this point in the history
  • Loading branch information
AbhinavTuli authored Mar 5, 2022
1 parent 6ef9381 commit 364ce3a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions hub/core/chunk_engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -396,7 +396,7 @@ def active_appended_chunk(self):
@active_appended_chunk.setter
def active_appended_chunk(self, value):
if self.active_appended_chunk is not None:
self.cache.remove_hub_object(self.active_appended_chunk)
self.cache.remove_hub_object(self.active_appended_chunk.key)
self._active_appended_chunk = value
if value is not None:
self.cache.register_hub_object(value.key, value)
Expand All @@ -408,7 +408,7 @@ def active_updated_chunk(self):
@active_updated_chunk.setter
def active_updated_chunk(self, value):
if self.active_updated_chunk is not None:
self.cache.remove_hub_object(self.active_updated_chunk)
self.cache.remove_hub_object(self.active_updated_chunk.key)
self._active_updated_chunk = value
if value is not None:
self.cache.register_hub_object(value.key, value)
Expand Down

0 comments on commit 364ce3a

Please sign in to comment.