changeset 2768:b1b1aa6f275c

allow None for path of hg.repository
author Vadim Gelfer <vadim.gelfer@gmail.com>
date Wed, 02 Aug 2006 12:46:00 -0700
parents 60683ab1ed33
children 2ace3bf43089
files mercurial/hg.py
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/hg.py	Wed Aug 02 10:48:34 2006 -0700
+++ b/mercurial/hg.py	Wed Aug 02 12:46:00 2006 -0700
@@ -13,7 +13,8 @@
 demandload(globals(), "errno lock os shutil util")
 
 def _local(path):
-    return os.path.isfile(util.drop_scheme('file', path)) and bundlerepo or localrepo
+    return (os.path.isfile(path and util.drop_scheme('file', path)) and
+            bundlerepo or localrepo)
 
 schemes = {
     'bundle': bundlerepo,