Skip to content

Commit

Permalink
Merge pull request #380 from kikkomep/fix/cleanup-gh-repo
Browse files Browse the repository at this point in the history
fix: local_repo reference
  • Loading branch information
kikkomep authored Feb 27, 2024
2 parents 7e78d25 + c91be61 commit b826751
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lifemonitor/api/models/repositories/github.py
Original file line number Diff line number Diff line change
Expand Up @@ -382,9 +382,9 @@ def __del__(self):
def cleanup(self) -> None:
logger.debug("Repository cleanup")
if getattr(self, "_local_repo", None):
local_repo_path = self.local_repo.local_path
local_repo_path = self._local_repo.local_path
del self._local_repo
logger.debug("Removing temp folder %r of %r", self.local_path, self)
logger.debug("Removing temp folder %r of %r", self._local_path, self)
shutil.rmtree(local_repo_path, ignore_errors=True)
self._local_repo = None

Expand Down

0 comments on commit b826751

Please sign in to comment.