(self, headers)
Prepares the given HTTP headers.
Prepares the given HTTP headers.
Prepares the given HTTP headers .
def prepare_headers(self, headers):
        """Prepares the given HTTP headers."""

        self.headers = CaseInsensitiveDict()
        if headers:
            for header in headers.items():
                # Raise exception on invalid header value.
                check_header_validity(header)
                name, value = header
                self.headers[to_native_string(name)] = value
def prepare_headers ( self , headers ) : self . headers = CaseInsensitiveDict ( ) if headers : for header in headers . items ( ) : # Raise exception on invalid header value. check_header_validity ( header ) name , value = header self . headers [ to_native_string ( name ) ] = value