Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: change Debug of Error to output url as str #2329

Merged
merged 1 commit into from
Jun 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/async_impl/response.rs
Original file line number Diff line number Diff line change
Expand Up @@ -432,7 +432,7 @@ impl Response {
impl fmt::Debug for Response {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
f.debug_struct("Response")
.field("url", self.url())
.field("url", &self.url().as_str())
.field("status", &self.status())
.field("headers", self.headers())
.finish()
Expand Down
2 changes: 1 addition & 1 deletion src/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ impl fmt::Debug for Error {
builder.field("kind", &self.inner.kind);

if let Some(ref url) = self.inner.url {
builder.field("url", url);
builder.field("url", &url.as_str());
}
if let Some(ref source) = self.inner.source {
builder.field("source", source);
Expand Down