summaryrefslogtreecommitdiffstats
path: root/Lib/gettext.py
diff options
context:
space:
mode:
authorRaymond Hettinger <python@rcn.com>2004-05-04 09:21:43 (GMT)
committerRaymond Hettinger <python@rcn.com>2004-05-04 09:21:43 (GMT)
commitbac788a3cd348203a5fdabba52e5faf65bf35c5e (patch)
tree3c5bfe8295936ad51df617ef0fd053ebac684357 /Lib/gettext.py
parentc5e378da41641d5bc1e9b5c6c11bd470ff90b3e3 (diff)
downloadcpython-bac788a3cd348203a5fdabba52e5faf65bf35c5e.zip
cpython-bac788a3cd348203a5fdabba52e5faf65bf35c5e.tar.gz
cpython-bac788a3cd348203a5fdabba52e5faf65bf35c5e.tar.bz2
Replace str.find()!=1 with the more readable "in" operator.
Diffstat (limited to 'Lib/gettext.py')
-rw-r--r--Lib/gettext.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/gettext.py b/Lib/gettext.py
index ed9d3ea..920aa46 100644
--- a/Lib/gettext.py
+++ b/Lib/gettext.py
@@ -289,7 +289,7 @@ class GNUTranslations(NullTranslations):
# cause no problems since us-ascii should always be a subset of
# the charset encoding. We may want to fall back to 8-bit msgids
# if the Unicode conversion fails.
- if msg.find('\x00') >= 0:
+ if '\x00' in msg:
# Plural forms
msgid1, msgid2 = msg.split('\x00')
tmsg = tmsg.split('\x00')