]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Improve readability of `formataddr` docstring (GH-20963)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Fri, 19 Jun 2020 12:15:57 +0000 (05:15 -0700)
committerGitHub <noreply@github.com>
Fri, 19 Jun 2020 12:15:57 +0000 (05:15 -0700)
For me as a non native English speaker, the sentence with its embedded clause was very hard to understand.

modified:   Lib/email/utils.py

Automerge-Triggered-By: @csabella
(cherry picked from commit 66a65ba43cb3e68a43e32469c988dd7a6cff049c)

Co-authored-by: Jürgen Gmach <juergen.gmach@googlemail.com>
Lib/email/utils.py

index 858f620e25bfb0127c35e62aad22b6bfd33ad0de..07dd029cc02800e2e32f0196da7f5fba722dd105 100644 (file)
@@ -81,7 +81,7 @@ def formataddr(pair, charset='utf-8'):
     If the first element of pair is false, then the second element is
     returned unmodified.
 
-    Optional charset if given is the character set that is used to encode
+    The optional charset is the character set that is used to encode
     realname in case realname is not ASCII safe.  Can be an instance of str or
     a Charset-like object which has a header_encode method.  Default is
     'utf-8'.