#8092 closed (fixed)
removing has_key, __getitem__ and contains from HttpRequest
Reported by: | Uz | Owned by: | nobody |
---|---|---|---|
Component: | HTTP handling | Version: | dev |
Severity: | Keywords: | ||
Cc: | Triage Stage: | Unreviewed | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
As django's template language first does a dictionary lookup, these methods lead to trouble with in connection with the request context_processor, as suggested in ticket #3828. To my knowledge it is advised to use request.REQUEST instead, anyways. So here's a patch to remove it.
Attachments (1)
Change History (5)
by , 16 years ago
Attachment: | request.__getitem__.patch added |
---|
comment:2 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
(In [8202]) Fixed #8092, #3828 -- Removed dictionary access for request objects so that GET and POST data doesn't "overwrite" request attributes when used in templates (since dictionary lookup is performed before attribute lookup). This is backwards-incompatible if you were using the request object for dictionary access to the combined GET and POST data, but you should use request.REQUEST
for that instead.
removes getitem contains and has_key from HttpRequest