mirror of
https://github.com/python/cpython.git
synced 2025-12-15 21:44:50 +00:00
Replaced .keys() with dictionary iterators
This commit is contained in:
parent
1fab9ee085
commit
e0d4972acc
9 changed files with 46 additions and 50 deletions
|
|
@ -24,11 +24,11 @@ def getcaps():
|
|||
continue
|
||||
morecaps = readmailcapfile(fp)
|
||||
fp.close()
|
||||
for key in morecaps.keys():
|
||||
for key, value in morecaps.iteritems():
|
||||
if not key in caps:
|
||||
caps[key] = morecaps[key]
|
||||
caps[key] = value
|
||||
else:
|
||||
caps[key] = caps[key] + morecaps[key]
|
||||
caps[key] = caps[key] + value
|
||||
return caps
|
||||
|
||||
def listmailcapfiles():
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue