mirror of
https://github.com/python/cpython.git
synced 2025-09-16 05:36:29 +00:00
replace has_key with 'in' operator
This commit is contained in:
parent
de0559998f
commit
6e3dbbdf39
29 changed files with 71 additions and 71 deletions
|
@ -107,7 +107,7 @@ class FileDialog:
|
|||
self.top.bind('<Alt-W>', self.cancel_command)
|
||||
|
||||
def go(self, dir_or_file=os.curdir, pattern="*", default="", key=None):
|
||||
if key and dialogstates.has_key(key):
|
||||
if key and key in dialogstates:
|
||||
self.directory, pattern = dialogstates[key]
|
||||
else:
|
||||
dir_or_file = os.path.expanduser(dir_or_file)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue