Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 56d7913

Browse files
committed
[Patch #900071] Be case-insensitive when removing 'usage:' string
1 parent 9303777 commit 56d7913

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Lib/optparse.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1033,7 +1033,7 @@ def set_usage (self, usage):
10331033
self.usage = "%prog [options]"
10341034
elif usage is SUPPRESS_USAGE:
10351035
self.usage = None
1036-
elif usage.startswith("usage: "):
1036+
elif usage.lower().startswith("usage: "):
10371037
# for backwards compatibility with Optik 1.3 and earlier
10381038
self.usage = usage[7:]
10391039
else:

0 commit comments

Comments
 (0)