summaryrefslogtreecommitdiffstats
path: root/Lib/http
diff options
context:
space:
mode:
authorIman Kermani <55282537+IKermani@users.noreply.github.com>2022-04-21 01:45:24 (GMT)
committerGitHub <noreply@github.com>2022-04-21 01:45:24 (GMT)
commit615b24c80b0bbbc7b70aa1e9c28f9c4463c8c1ed (patch)
tree681ceb78d2709f4b39aa2082b49270aec7a1d0b1 /Lib/http
parent031f1e6040d1bb0454bd6da417fd9e38aad4fc89 (diff)
downloadcpython-615b24c80b0bbbc7b70aa1e9c28f9c4463c8c1ed.zip
cpython-615b24c80b0bbbc7b70aa1e9c28f9c4463c8c1ed.tar.gz
cpython-615b24c80b0bbbc7b70aa1e9c28f9c4463c8c1ed.tar.bz2
bpo-42066: CookieJar cookies should not be sorted (GH-22745)
Diffstat (limited to 'Lib/http')
-rw-r--r--Lib/http/cookiejar.py9
1 files changed, 2 insertions, 7 deletions
diff --git a/Lib/http/cookiejar.py b/Lib/http/cookiejar.py
index 136a1f16..f19a366 100644
--- a/Lib/http/cookiejar.py
+++ b/Lib/http/cookiejar.py
@@ -1224,14 +1224,9 @@ class DefaultCookiePolicy(CookiePolicy):
_debug(" %s does not path-match %s", req_path, path)
return False
-def vals_sorted_by_key(adict):
- keys = sorted(adict.keys())
- return map(adict.get, keys)
-
def deepvalues(mapping):
- """Iterates over nested mapping, depth-first, in sorted order by key."""
- values = vals_sorted_by_key(mapping)
- for obj in values:
+ """Iterates over nested mapping, depth-first"""
+ for obj in list(mapping.values()):
mapping = False
try:
obj.items