summaryrefslogtreecommitdiff
path: root/git/objects/submodule/base.py
diff options
context:
space:
mode:
Diffstat (limited to 'git/objects/submodule/base.py')
-rw-r--r--git/objects/submodule/base.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/git/objects/submodule/base.py b/git/objects/submodule/base.py
index eea091f8..fb5f774d 100644
--- a/git/objects/submodule/base.py
+++ b/git/objects/submodule/base.py
@@ -848,6 +848,7 @@ class Submodule(util.IndexObject, Iterable, Traversable):
# finally delete our own submodule
if not dry_run:
+ self._clear_cache()
wtd = mod.working_tree_dir
del(mod) # release file-handles (windows)
rmtree(wtd)
@@ -855,6 +856,7 @@ class Submodule(util.IndexObject, Iterable, Traversable):
# END handle force
if not dry_run and os.path.isdir(git_dir):
+ self._clear_cache()
rmtree(git_dir)
# end handle separate bare repository
# END handle module deletion