Skip to content

Loading…

Fixes #21154 -- Update TemplateResponse docs #1694

Closed
wants to merge 1 commit into from

2 participants

@funkybob

Simply expand the documentation to clarify that if passed a Context instance, it won't be replaced.

@funkybob

Oh, and I tidied up the indenting, too.

@timgraham
Django member

merged in c39c9f2 - thanks!

@timgraham timgraham closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Sep 30, 2013
  1. @funkybob
Showing with 7 additions and 4 deletions.
  1. +7 −4 docs/ref/template-response.txt
View
11 docs/ref/template-response.txt
@@ -132,10 +132,13 @@ TemplateResponse objects
.. class:: TemplateResponse()
- TemplateResponse is a subclass of
- :class:`~django.template.response.SimpleTemplateResponse` that uses
- a :class:`~django.template.RequestContext` instead of
- a :class:`~django.template.Context`.
+ TemplateResponse is a subclass of
+ :class:`~django.template.response.SimpleTemplateResponse` that uses
+ a :class:`~django.template.RequestContext` instead of
+ a :class:`~django.template.Context`.
+
+ If you pass a :class:`~django.template.Context` instance or subclass, it
+ will be used instead of creating a new one.
Methods
-------
Something went wrong with that request. Please try again.