From bd219edc4571806edf80fd6a48c8ac3fbbadcf22 Mon Sep 17 00:00:00 2001 From: Adrian Garcia Badaracco <1755071+adriangb@users.noreply.github.com> Date: Sun, 14 Aug 2022 05:39:02 -0500 Subject: [PATCH] Remove unecessary override of Headers.get (#1810) --- starlette/datastructures.py | 6 ------ 1 file changed, 6 deletions(-) diff --git a/starlette/datastructures.py b/starlette/datastructures.py index f49dbc35..42ec7a9e 100644 --- a/starlette/datastructures.py +++ b/starlette/datastructures.py @@ -540,12 +540,6 @@ class Headers(typing.Mapping[str, str]): for key, value in self._list ] - def get(self, key: str, default: typing.Any = None) -> typing.Any: - try: - return self[key] - except KeyError: - return default - def getlist(self, key: str) -> typing.List[str]: get_header_key = key.lower().encode("latin-1") return [