Mercurial > hg
changeset 6500:a3175cd7dbec
Tidy code, fix typo
author | Bryan O'Sullivan <bos@serpentine.com> |
---|---|
date | Wed, 09 Apr 2008 15:27:57 -0700 |
parents | 479847ccabe0 |
children | 4f7feeb6d6ee |
files | mercurial/util.py |
diffstat | 1 files changed, 4 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/util.py Thu Dec 20 20:02:51 2007 +0000 +++ b/mercurial/util.py Wed Apr 09 15:27:57 2008 -0700 @@ -569,12 +569,13 @@ Defaults to $HG or 'hg' in the search path. """ if _hgexecutable is None: - if os.environ.has_key('HG'): - set_hgexecutable(os.environ.get('HG')) + hg = os.environ.get('HG') + if hg: + set_hgexecutable(hg) elif main_is_frozen(): set_hgexecutable(sys.executable) else: - sel_hgexecutable(find_exe('hg', 'hg')) + set_hgexecutable(find_exe('hg', 'hg')) return _hgexecutable def set_hgexecutable(path):