summaryrefslogtreecommitdiffstats
path: root/Lib/bsddb
diff options
context:
space:
mode:
authorSteve Holden <steve@holdenweb.com>2005-02-02 18:47:18 (GMT)
committerSteve Holden <steve@holdenweb.com>2005-02-02 18:47:18 (GMT)
commit69b8caa23a598f3192981898eb213f9578fbf0be (patch)
tree6bfdd697471e4efb8c354bb4c8276d135b4bdf5a /Lib/bsddb
parentfaa7648ffe6fbc568eeb6457815bd85cef21bfbd (diff)
downloadcpython-69b8caa23a598f3192981898eb213f9578fbf0be.zip
cpython-69b8caa23a598f3192981898eb213f9578fbf0be.tar.gz
cpython-69b8caa23a598f3192981898eb213f9578fbf0be.tar.bz2
Simplify string comparison using startswith()
Diffstat (limited to 'Lib/bsddb')
-rw-r--r--Lib/bsddb/db.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/bsddb/db.py b/Lib/bsddb/db.py
index b2ee14e..3bd0c8b 100644
--- a/Lib/bsddb/db.py
+++ b/Lib/bsddb/db.py
@@ -37,7 +37,7 @@
# case we ever want to augment the stuff in _db in any way. For now
# it just simply imports everything from _db.
-if __name__[:len('bsddb3.')] == 'bsddb3.':
+if __name__.startswith('bsddb3.'):
# import _pybsddb binary as it should be the more recent version from
# a standalone pybsddb addon package than the version included with
# python as bsddb._bsddb.