objective-git
objective-git copied to clipboard
Fixes crash caused by GTRepository dealloc
When the system calls -[GTRepository dealloc] and the git_repository is empty, but still exists, the app crashes.
Here is a screenshot of the debug session:

To fix this, the function is simply checking if the workdir property of the git_repository object isn't empty before cleaning the repo.
This PR fixes #689