﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
20459	Better example for setting header fields in documentation	bbjay	nobody	"I think the current example for setting header fields in HttpResponse objects is a bit unfortunate:
https://docs.djangoproject.com/en/dev/ref/request-response/#setting-header-fields

The Cache-Control field (also the Vary field) is a comma-separated multi value field.
e.g. `Cache-Control: public, max-age=60`
Setting its value by a dictionary access can unintentionally remove other present values, e.g. set by another middleware.

My proposed solution: change example to use 'Age' header field, mention and encourage use of patch_vary_header and patch_cache_control methods.
https://github.com/bbjay/django/commit/227f4bf4fe7971754ecc09aeb141b824a3f0550b"	Cleanup/optimization	closed	Documentation	dev	Normal	fixed		bbjay	Accepted	1	0	0	0	0	0
