Skip to content

Commit 8f56ac8

Browse files
committed
Change quirks::origin to return ASCII serialization
1 parent 73fc76e commit 8f56ac8

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/quirks.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ pub fn set_href(url: &mut Url, value: &str) -> Result<(), ParseError> {
4646

4747
/// Getter for https://url.spec.whatwg.org/#dom-url-origin
4848
pub fn origin(url: &Url) -> String {
49-
url.origin().unicode_serialization()
49+
url.origin().ascii_serialization()
5050
}
5151

5252
/// Getter for https://url.spec.whatwg.org/#dom-url-protocol

tests/urltestdata.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3536,7 +3536,7 @@
35363536
"input": "http://你好你好",
35373537
"base": "http://other.com/",
35383538
"href": "http://xn--6qqa088eba/",
3539-
"origin": "http://你好你好",
3539+
"origin": "http://xn--6qqa088eba",
35403540
"protocol": "http:",
35413541
"username": "",
35423542
"password": "",

0 commit comments

Comments
 (0)