Skip to content

Commit

Permalink
More explicit naming
Browse files Browse the repository at this point in the history
  • Loading branch information
alexmojaki committed Dec 23, 2024
1 parent a4f1653 commit bd76022
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions logfire/_internal/integrations/httpx.py
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ def body_is_streaming(self):
return not isinstance(self.stream, httpx.ByteStream)

@property
def content_type_header(self) -> ContentTypeHeader:
def content_type_header_object(self) -> ContentTypeHeader:
return content_type_header_from_string(self.content_type_header_string)

@property
Expand All @@ -194,8 +194,8 @@ def content_type_is_form(self):
return content_type == 'application/x-www-form-urlencoded'

@property
def charset(self):
return self.content_type_header.params.get('charset', 'utf-8')
def content_type_charset(self):
return self.content_type_header_object.params.get('charset', 'utf-8')

@property
def content(self) -> bytes:
Expand All @@ -205,7 +205,7 @@ def content(self) -> bytes:

@property
def text(self) -> str:
return decode_body(self.content, self.charset)
return decode_body(self.content, self.content_type_charset)

@property
def form_data(self) -> Mapping[str, Any] | None:
Expand Down

0 comments on commit bd76022

Please sign in to comment.