fix browser2 to be compliant with python-requests >= 2.0

This commit is contained in:
Romain Bignon 2014-03-09 15:39:43 +01:00
commit 5e199bdfa9
3 changed files with 45 additions and 180 deletions

View file

@ -866,8 +866,8 @@ class Cookie(object):
value = renderer(value)
return '; '.join(
[''.join((prefix, name, '=', value))] +
[key if isinstance(value, bool) else '='.join((key, value))
for key, value in self.attributes().items()])
[k if isinstance(v, bool) else '='.join((k, v))
for k, v in self.attributes().items()])
def __eq__(self, other):
attrs = ['name', 'value'] + list(self.attribute_names.keys())