# HG changeset patch # User Drew Gottlieb # Date 1426285965 25200 # Node ID 79d9c51488ca2fb11384331f48de1986ee89a87b # Parent 149cc171e4a0621183cf72c1fa16b1ecf64ff48d manifest: add hasdir() to context This is a convenience method that calls to its manifest's hasdir(). There are parts of context that check to see if a directory exists, and this method will let implementations of manifest provide an optimal way to find a particular directory. diff -r 149cc171e4a0 -r 79d9c51488ca mercurial/context.py --- a/mercurial/context.py Fri Mar 13 15:25:01 2015 -0700 +++ b/mercurial/context.py Fri Mar 13 15:32:45 2015 -0700 @@ -269,6 +269,8 @@ def dirs(self): return self._manifest.dirs() + def hasdir(self, dir): + return self._manifest.hasdir(dir) def dirty(self, missing=False, merge=True, branch=True): return False