Opened 10 years ago

Closed 10 years ago

#2503 closed defect (fixed)

[patch] max_age should be max-age in HttpResponse.delete_cookie

Reported by: Ludovico Magnocavallo Owned by: Adrian Holovaty
Component: Core (Other) Version:
Severity: normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

The HttpResponse.delete_cookie method uses the 'max_age' key instead of 'max-age', resulting in a Cookie error raised by Cookie.py" in setitem with the following message: 'Invalid Attribute max_age'.

Mini-patch following.

Attachments (1)

delete_cookie.diff (469 bytes) - added by ludo@… 10 years ago.

Download all attachments as: .zip

Change History (3)

Changed 10 years ago by ludo@…

Attachment: delete_cookie.diff added

comment:1 Changed 10 years ago by anonymous

Summary: max_age should be max-age in HttpResponse.delete_cookie[patch] max_age should be max-age in HttpResponse.delete_cookie

comment:2 Changed 10 years ago by Adrian Holovaty

Resolution: fixed
Status: newclosed

(In [3545]) Fixed #2503 -- Fixed HttpResponse.delete_cookie() to work properly. It now takes path and domain as optional keyword arguments.

Note: See TracTickets for help on using tickets.
Back to Top