mirror of https://github.com/python/cpython
Issue #5275: In Cookie's Cookie.load(), properly handle non-string arguments as documented.
This commit is contained in:
parent
fe18a11858
commit
d22b9519d1
|
@ -624,7 +624,9 @@ class BaseCookie(dict):
|
|||
if type(rawdata) == type(""):
|
||||
self.__ParseString(rawdata)
|
||||
else:
|
||||
self.update(rawdata)
|
||||
# self.update() wouldn't call our custom __setitem__
|
||||
for k, v in rawdata.items():
|
||||
self[k] = v
|
||||
return
|
||||
# end load()
|
||||
|
||||
|
|
Loading…
Reference in New Issue