util.getuser: better comments
authorVadim Gelfer <vadim.gelfer@gmail.com>
Mon, 24 Jul 2006 09:22:47 -0700
changeset 2648 df5e58c84b01
parent 2647 c54ecfc360a9
child 2649 e6a7a6a33a62
child 2657 6024216754f4
util.getuser: better comments
mercurial/util.py
--- a/mercurial/util.py
+++ b/mercurial/util.py
@@ -517,10 +517,12 @@ def getuser():
     try:
         return getpass.getuser()
     except ImportError:
+        # import of pwd will fail on windows - try fallback
         if getuser_fallback:
             return getuser_fallback()
-    raise util.Abort(_('user name not available - set USERNAME '
-                       'environment variable'))
+    # raised if win32api not available
+    raise Abort(_('user name not available - set USERNAME '
+                  'environment variable'))
 
 # Platform specific variants
 if os.name == 'nt':