Skip to content

Commit

Permalink
fixup! url: prevent pathname setter from erasing path of path-only URLs
Browse files Browse the repository at this point in the history
  • Loading branch information
RaisinTen committed Jun 26, 2021
1 parent 143d369 commit 9c2bed4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/node_url.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1477,7 +1477,7 @@ void URL::Parse(const char* input,
if (ch != '/') {
continue;
}
} else if (has_state_override && url->host.empty()) {
} else if (has_state_override && !(url->flags & URL_FLAGS_HAS_HOST)) {
url->path.emplace_back("");
}
break;
Expand Down

0 comments on commit 9c2bed4

Please sign in to comment.