mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 05:37:34 +00:00
URL: No need to include ":80" when serializing http:// URLs
This commit is contained in:
parent
c294c97cdf
commit
bf5a65d934
1 changed files with 4 additions and 2 deletions
|
@ -125,9 +125,11 @@ String URL::to_string() const
|
||||||
builder.append("://");
|
builder.append("://");
|
||||||
if (protocol() != "file") {
|
if (protocol() != "file") {
|
||||||
builder.append(m_host);
|
builder.append(m_host);
|
||||||
|
if (protocol() != "http" || port() != 80) {
|
||||||
builder.append(':');
|
builder.append(':');
|
||||||
builder.append(String::number(m_port));
|
builder.append(String::number(m_port));
|
||||||
}
|
}
|
||||||
|
}
|
||||||
builder.append(m_path);
|
builder.append(m_path);
|
||||||
return builder.to_string();
|
return builder.to_string();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue