VMM: Deleted a few unused variables. v0.6.x
authorPascal Volk <neverseen@users.sourceforge.net>
Thu, 10 Mar 2011 19:34:28 +0000
branchv0.6.x
changeset 422 33a45e4c80c4
parent 421 ff2a61e155db
child 423 a43a2e20de71
VMM: Deleted a few unused variables.
VirtualMailManager/cli/handler.py
VirtualMailManager/ext/postconf.py
VirtualMailManager/handler.py
VirtualMailManager/mailbox.py
--- a/VirtualMailManager/cli/handler.py	Sat Mar 05 22:46:17 2011 +0000
+++ b/VirtualMailManager/cli/handler.py	Thu Mar 10 19:34:28 2011 +0000
@@ -76,7 +76,7 @@
         if acc:
             raise VMMError(_(u"The account '%s' already exists.") %
                            acc.address, ACCOUNT_EXISTS)
-        other = self._is_other_address(acc.address, TYPE_ACCOUNT)
+        self._is_other_address(acc.address, TYPE_ACCOUNT)
         rand_pass = self._cfg.dget('account.random_password')
         if password is None:
             password = (read_pass, randompw)[rand_pass]()
--- a/VirtualMailManager/ext/postconf.py	Sat Mar 05 22:46:17 2011 +0000
+++ b/VirtualMailManager/ext/postconf.py	Thu Mar 10 19:34:28 2011 +0000
@@ -50,8 +50,8 @@
           the parameter's new value.
         """
         self._check_parameter(parameter)
-        stdout, stderr = Popen((self._bin, '-e', parameter + '=' + str(value)),
-                               stderr=PIPE).communicate()
+        stderr = Popen((self._bin, '-e', parameter + '=' + str(value)),
+                       stderr=PIPE).communicate()[1]
         if stderr:
             raise VMMError(stderr.strip(), VMM_ERROR)
 
--- a/VirtualMailManager/handler.py	Sat Mar 05 22:46:17 2011 +0000
+++ b/VirtualMailManager/handler.py	Thu Mar 10 19:34:28 2011 +0000
@@ -572,7 +572,7 @@
         if acc:
             raise VMMError(_(u"The account '%s' already exists.") %
                            acc.address, ACCOUNT_EXISTS)
-        other = self._is_other_address(acc.address, TYPE_ACCOUNT)
+        self._is_other_address(acc.address, TYPE_ACCOUNT)
         acc.set_password(password)
         acc.save()
         self._make_account_dirs(acc)
--- a/VirtualMailManager/mailbox.py	Sat Mar 05 22:46:17 2011 +0000
+++ b/VirtualMailManager/mailbox.py	Thu Mar 10 19:34:28 2011 +0000
@@ -254,8 +254,8 @@
         if subscribe:
             cmd_args.append('-s')
         cmd_args.extend(mailboxes)
-        process = Popen(cmd_args, stdout=PIPE, stderr=PIPE)
-        stdout, stderr = process.communicate()
+        process = Popen(cmd_args, stderr=PIPE)
+        stderr = process.communicate()[1]
         if process.returncode:
             e_msg = _(u'Failed to create mailboxes: %r\n') % mailboxes
             raise VMMError(e_msg + stderr.strip(), VMM_ERROR)