Mercurial > hg
diff hgext/convert/git.py @ 14945:11aad09a6370
hgext: replace uses of hasattr with util.safehasattr
author | Augie Fackler <durin42@gmail.com> |
---|---|
date | Mon, 25 Jul 2011 20:37:12 -0500 |
parents | d297ee0b2d94 |
children | 589aab2ca716 101c8a1befb1 |
line wrap: on
line diff
--- a/hgext/convert/git.py Mon Jul 25 15:30:19 2011 -0500 +++ b/hgext/convert/git.py Mon Jul 25 20:37:12 2011 -0500 @@ -16,7 +16,7 @@ # Windows does not support GIT_DIR= construct while other systems # cannot remove environment variable. Just assume none have # both issues. - if hasattr(os, 'unsetenv'): + if util.safehasattr(os, 'unsetenv'): def gitopen(self, s, noerr=False): prevgitdir = os.environ.get('GIT_DIR') os.environ['GIT_DIR'] = self.path