From 0da212ffbf5f22cfb1ad1f11bc30a45cee2fce82 Mon Sep 17 00:00:00 2001 From: MAHANTH-wq Date: Thu, 1 Oct 2020 11:05:59 +0530 Subject: [PATCH] Fixed #32057 -- Doc'd HttpResponse.get()/items(). --- docs/ref/request-response.txt | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/docs/ref/request-response.txt b/docs/ref/request-response.txt index 40063becc92..8dae4455a2a 100644 --- a/docs/ref/request-response.txt +++ b/docs/ref/request-response.txt @@ -843,11 +843,20 @@ Methods Returns the value for the given header name. Case-insensitive. +.. method:: HttpResponse.get(header, alternate=None) + + Returns the value for the given header, or an ``alternate`` if the header + doesn't exist. + .. method:: HttpResponse.has_header(header) Returns ``True`` or ``False`` based on a case-insensitive check for a header with the given name. +.. method:: HttpResponse.items() + + Acts like :meth:`dict.items` for HTTP headers on the response. + .. method:: HttpResponse.setdefault(header, value) Sets a header unless it has already been set.