summaryrefslogtreecommitdiff
path: root/setuptools/command/upload_docs.py
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2013-11-27 13:38:46 -0500
committerJason R. Coombs <jaraco@jaraco.com>2013-11-27 13:38:46 -0500
commitfc7d6886301ce8b5dffb22a9ac320dbf488205d5 (patch)
tree0093e5b76f912e94a42379112e59853176753fad /setuptools/command/upload_docs.py
parent2cb2a7534489ac19d265dfce820722de55bd05fb (diff)
downloadpython-setuptools-bitbucket-fc7d6886301ce8b5dffb22a9ac320dbf488205d5.tar.gz
Use ternary operator to select encoding error behavior.
Diffstat (limited to 'setuptools/command/upload_docs.py')
-rw-r--r--setuptools/command/upload_docs.py5
1 files changed, 1 insertions, 4 deletions
diff --git a/setuptools/command/upload_docs.py b/setuptools/command/upload_docs.py
index a69958d8..8ee35cb0 100644
--- a/setuptools/command/upload_docs.py
+++ b/setuptools/command/upload_docs.py
@@ -21,10 +21,7 @@ from distutils.command.upload import upload
from setuptools.compat import httplib, urlparse, unicode, iteritems, PY3
-if PY3:
- errors = 'surrogateescape'
-else:
- errors = 'strict'
+errors = 'surrogateescape' if PY3 else 'strict'
# This is not just a replacement for byte literals