only check tracked files if there is a repo

This commit is contained in:
Paul Gauthier 2023-08-17 10:44:33 -07:00
parent 6c2923ff70
commit fef5a7b917

View file

@ -739,6 +739,7 @@ class Coder:
def allowed_to_edit(self, path):
full_path = self.abs_root_path(path)
if self.repo:
tracked_files = set(self.repo.get_tracked_files())
is_in_repo = path in tracked_files