summaryrefslogtreecommitdiffstats
path: root/Lib/collections.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/collections.py')
-rw-r--r--Lib/collections.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/collections.py b/Lib/collections.py
index 3c1b78a..a90915a 100644
--- a/Lib/collections.py
+++ b/Lib/collections.py
@@ -122,7 +122,7 @@ class OrderedDict(dict, MutableMapping):
'''
if not self:
raise KeyError('dictionary is empty')
- key = next(reversed(self)) if last else next(iter(self))
+ key = next(reversed(self) if last else iter(self))
value = self.pop(key)
return key, value