# HG changeset patch # User Idan Kamara # Date 2013-01-10 21:57:03 # Node ID 948f495fb2302a6241787a2d5924ef328f2f4967 # Parent 365fecd984c7beb451bd074585175a70f78d6765 localrepo: drop unnecessary check on wlock unlock Calling out to dirstate one line before guarantees that it'll be in the filecache. diff --git a/mercurial/localrepo.py b/mercurial/localrepo.py --- a/mercurial/localrepo.py +++ b/mercurial/localrepo.py @@ -1033,9 +1033,7 @@ class localrepository(object): def unlock(): self.dirstate.write() - ce = self._filecache.get('dirstate') - if ce: - ce.refresh() + self._filecache['dirstate'].refresh() l = self._lock(self.join("wlock"), wait, unlock, self.invalidatedirstate, _('working directory of %s') %