diff options
author | Georg Brandl <georg@python.org> | 2006-06-09 20:43:48 +0000 |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2006-06-09 20:43:48 +0000 |
commit | 0e3e7b6645ee922c4d2d922513d4e63ef65cafd8 (patch) | |
tree | 8a4f18f98f8637f58ce14f5cfd3fc8e9e676f5b4 /Lib/webbrowser.py | |
parent | 63326bf54f9c578ff6b04f0078808dc585fa03b8 (diff) | |
download | cpython-0e3e7b6645ee922c4d2d922513d4e63ef65cafd8.tar.gz |
Make use of new str.startswith/endswith semantics.
Occurences in email and compiler were ignored due to backwards compat requirements.
Diffstat (limited to 'Lib/webbrowser.py')
-rw-r--r-- | Lib/webbrowser.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/Lib/webbrowser.py b/Lib/webbrowser.py index 4693fe7568..bae0caf4a0 100644 --- a/Lib/webbrowser.py +++ b/Lib/webbrowser.py @@ -98,8 +98,7 @@ def _synthesize(browser, update_tryorder=1): if sys.platform[:3] == "win": def _isexecutable(cmd): cmd = cmd.lower() - if os.path.isfile(cmd) and (cmd.endswith(".exe") or - cmd.endswith(".bat")): + if os.path.isfile(cmd) and cmd.endswith((".exe", ".bat")): return True for ext in ".exe", ".bat": if os.path.isfile(cmd + ext): |