]> granicus.if.org Git - python/commitdiff
Fix suggested by movits@lockstar.com (plus doc string by myself)
authorGuido van Rossum <guido@python.org>
Wed, 2 Sep 1998 14:42:02 +0000 (14:42 +0000)
committerGuido van Rossum <guido@python.org>
Wed, 2 Sep 1998 14:42:02 +0000 (14:42 +0000)
for LIST command with msg argument.

Lib/poplib.py

index 2539892e64a6b0c5ba12eeb0f81f573cd2092aa7..0f588c15f10da2f3ba183b9c92a23741415bb7b2 100644 (file)
@@ -196,14 +196,17 @@ class POP3:
                return (numMessages, sizeMessages)
 
 
-       def list(self, which=None):
+       def list(self, msg=None):
                """Request listing, return result.
-               Result is in form ['response', ['mesg_num octets', ...]].
 
-               Unsure what the optional 'msg' arg does.
+               Result without a msg argument is in form
+               ['response', ['mesg_num octets', ...]].
+
+               Result when a msg argument is given is a single response:
+               the "scan listing" for that message.
                """
                if which:
-                       return self._longcmd('LIST %s' % which)
+                       return self._shortcmd('LIST %s' % which)
                return self._longcmd('LIST')