Opened 16 years ago

Closed 16 years ago

Last modified 13 years ago

#10586 closed (fixed)

@last_modified call condition(last_modified=callable), but condition expect last_modified_func

Reported by: qoqenator Owned by: Malcolm Tredinnick
Component: Uncategorized Version: 1.0
Severity: Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

REV. 10115

In django.views.decorators.http:

def etag(callable):
    return condition(etag=callable)

def last_modified(callable):
    return condition(last_modified=callable)

But:

def condition(etag_func=None, last_modified_func=None):
    ...

Attachments (1)

10586.patch (540 bytes ) - added by qoqenator 16 years ago.

Download all attachments as: .zip

Change History (5)

by qoqenator, 16 years ago

Attachment: 10586.patch added

comment:1 by Malcolm Tredinnick, 16 years ago

Owner: changed from nobody to Malcolm Tredinnick
Status: newassigned
Triage Stage: UnreviewedAccepted

I'm actually thinking I might just get rid of those two decorators and only keep conditional(), since they're not really such a huge shortcut and require lots of extra documentation.

Still, one way or the other, this needs fixing up. Thanks for noticing.

comment:2 by Malcolm Tredinnick, 16 years ago

milestone: 1.1

comment:3 by Malcolm Tredinnick, 16 years ago

Resolution: fixed
Status: assignedclosed

(In [10134]) A bunch of improvements for conditional HTTP processing.

Fixed some typos in the code (fixed #10586). Added more tests. Made the
tests compatible with Python 2.3. Improved the documentation by putting
the good news and common use-case right up front.

comment:4 by Jacob, 13 years ago

milestone: 1.1

Milestone 1.1 deleted

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