Ticket #15342: 15342.patch

File 15342.patch, 583 bytes (added by Jannis Vajen, 14 years ago)

Adds *args to decorated dispatch() example

  • docs/topics/class-based-views.txt

    diff --git a/docs/topics/class-based-views.txt b/docs/topics/class-based-views.txt
    index 516a315..0ad697c 100644
    a b that it can be used on an instance method. For example::  
    606606
    607607        @method_decorator(login_required)
    608608        def dispatch(self, **kwargs):
    609             return super(ProtectedView, self).dispatch(**kwargs)
     609            return super(ProtectedView, self).dispatch(*args, **kwargs)
    610610
    611611In this example, every instance of :class:`ProtectedView` will have
    612612login protection.
Back to Top