From 55e0abfa27b693768f495044d10444d9d92e4fca Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Sun, 13 Dec 2009 07:39:55 -0500 Subject: More fixes for libbe.storage.vcs.hg + .git transition. --- libbe/ui/util/user.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'libbe/ui/util') diff --git a/libbe/ui/util/user.py b/libbe/ui/util/user.py index 64eb30c..a58f83a 100644 --- a/libbe/ui/util/user.py +++ b/libbe/ui/util/user.py @@ -13,7 +13,7 @@ from socket import gethostname import libbe import libbe.storage.util.config -def _get_fallback_username(self): +def get_fallback_username(self): name = None for env in ["LOGNAME", "USERNAME"]: if os.environ.has_key(env): @@ -22,9 +22,9 @@ def _get_fallback_username(self): assert name != None return name -def _get_fallback_email(self): +def get_fallback_email(self): hostname = gethostname() - name = _get_fallback_username() + name = get_fallback_username() return "%s@%s" % (name, hostname) def create_user_id(name, email=None): @@ -77,9 +77,9 @@ def get_user_id(self, storage=None): user = vcs.get_user_id() if user != None: return user - name = _get_fallback_username() - email = _get_fallback_email() - user = _create_user_id(name, email) + name = get_fallback_username() + email = get_fallback_email() + user = create_user_id(name, email) return user def set_user_id(self, user_id): -- cgit