Skip to content

Commit

Permalink
[#43] Improvements 2
Browse files Browse the repository at this point in the history
  • Loading branch information
danielmursa-dev committed Nov 7, 2024
1 parent 35b9518 commit 6b27f34
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion log_outgoing_requests/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,9 @@ def request_body(self, obj) -> str:
def response_body(self, obj) -> str:
return obj.response_body_decoded or "-"

@admin.display(description=_("Response content length"))
def response_content_length(self, obj):
return obj.response_content_length or "-"
return obj.response_content_length

def truncated_url(self, obj):
parsed_url = urlparse(obj.url)
Expand Down
2 changes: 1 addition & 1 deletion log_outgoing_requests/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ def response_content_length(self) -> str:
"""
return str(len(self.response_body_decoded))

response_content_length.short_description = _("Content length") # type: ignore
response_content_length.short_description = _("Response content length") # type: ignore

def get_default_max_content_length():
"""
Expand Down

0 comments on commit 6b27f34

Please sign in to comment.