server/serverctl.py
branchstable
changeset 6072 9d83b214066a
parent 6060 353bec342e2a
child 6109 47d9c0e0f7b7
--- a/server/serverctl.py	Fri Aug 06 17:33:07 2010 +0200
+++ b/server/serverctl.py	Fri Aug 06 17:34:24 2010 +0200
@@ -71,13 +71,13 @@
                        'on the database:')
                 print special_privs
                 print
-        default_user = source.get('db-user', os.environ.get('USER', ''))
-        user = raw_input('Connect as user ? [%r]: ' % default_user)
-        user = user or default_user
-        if user == source.get('db-user') and source.get('db-password'):
-            password = source['db-password']
-        else:
-            password = getpass('password: ')
+            default_user = source.get('db-user', os.environ.get('USER', ''))
+            user = raw_input('Connect as user ? [%r]: ' % default_user)
+            user = user or default_user
+            if user == source.get('db-user') and source.get('db-password'):
+                password = source['db-password']
+            else:
+                password = getpass('password: ')
     else:
         user = password = None
     extra_args = source.get('db-extra-arguments')