#30699: Remove `PublisherDetail.get_context_data()` from documentation
-------------------------------------+-------------------------------------
     Reporter:  Davit Gachechiladze  |                    Owner:  Davit
         Type:                       |  Gachechiladze
  Cleanup/optimization               |                   Status:  closed
    Component:  Documentation        |                  Version:  2.2
     Severity:  Normal               |               Resolution:  wontfix
     Keywords:                       |             Triage Stage:
                                     |  Unreviewed
    Has patch:  1                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Changes (by Carlton Gibson):

 * status:  assigned => closed
 * resolution:   => wontfix


Comment:

 I think the override is serving a purpose here:

 > We have to think carefully about get_context_data(). Since both
 SingleObjectMixin and ListView will put things in the context data under
 the value of context_object_name if it’s set, we’ll instead explicitly
 ensure the Publisher is in the context data.

 Removing it is fragile. (Without it, as soon as I set
 `context_object_name` my code would break.)

 With this discussion kind of topic there's always other/better ways to do
 things but in context I think the existing example is fine.

 Thanks for the input.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/30699#comment:2>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/067.12494b7f7beb329721b8f9c70ba01f05%40djangoproject.com.

Reply via email to