MCPcopy
hub / github.com/django/django / parse_header_name

Method parse_header_name

django/http/request.py:540–545  ·  view source on GitHub ↗
(cls, header)

Source from the content-addressed store, hash-verified

538
539 @classmethod
540 def parse_header_name(cls, header):
541 if header.startswith(cls.HTTP_PREFIX):
542 header = header.removeprefix(cls.HTTP_PREFIX)
543 elif header not in cls.UNPREFIXED_HEADERS:
544 return None
545 return header.replace("_", "-").title()
546
547 @classmethod
548 def to_wsgi_name(cls, header):

Callers 3

__init__Method · 0.95
_bad_token_messageMethod · 0.80

Calls 1

titleMethod · 0.80

Tested by 1