Skip to content

Commit

Permalink
Remove Origin::unicode_serialization
Browse files Browse the repository at this point in the history
Fixes #20701
  • Loading branch information
Eijebong committed Oct 12, 2018
1 parent 61fe737 commit a97ba4f
Show file tree
Hide file tree
Showing 7 changed files with 3 additions and 35 deletions.
2 changes: 1 addition & 1 deletion components/net_traits/blob_url_store.rs
Expand Up @@ -57,6 +57,6 @@ pub fn get_blob_origin(url: &ServoUrl) -> FileOrigin {
// NOTE: by default this is "null" (Opaque), which is not ideal
"file://".to_string()
} else {
url.origin().unicode_serialization()
url.origin().ascii_serialization()
}
}
2 changes: 1 addition & 1 deletion components/script/dom/eventsource.rs
Expand Up @@ -340,7 +340,7 @@ impl FetchResponseListener for EventSourceContext {
None => self.fail_the_connection(),
Some(ct) => match ct.into_inner().0 {
Mime(TopLevel::Text, SubLevel::EventStream, _) => {
self.origin = meta.final_url.origin().unicode_serialization();
self.origin = meta.final_url.origin().ascii_serialization();
self.announce_the_connection();
},
_ => self.fail_the_connection(),
Expand Down
2 changes: 1 addition & 1 deletion components/script/dom/htmlanchorelement.rs
Expand Up @@ -319,7 +319,7 @@ impl HTMLAnchorElementMethods for HTMLAnchorElement {
},
Some(ref url) => {
// Step 3.
url.origin().unicode_serialization()
url.origin().ascii_serialization()
},
})
}
Expand Down
5 changes: 0 additions & 5 deletions components/url/origin.rs
Expand Up @@ -89,11 +89,6 @@ impl ImmutableOrigin {
pub fn ascii_serialization(&self) -> String {
self.clone().into_url_origin().ascii_serialization()
}

/// <https://html.spec.whatwg.org/multipage/#unicode-serialisation-of-an-origin>
pub fn unicode_serialization(&self) -> String {
self.clone().into_url_origin().unicode_serialization()
}
}

/// Opaque identifier for URLs that have file or other schemes
Expand Down
Expand Up @@ -9,12 +9,3 @@
[EventSource: cross-origin No allow-origin should fail]
expected: FAIL

[EventSource: cross-origin basic use]
expected: FAIL

[EventSource: cross-origin redirect use]
expected: FAIL

[EventSource: cross-origin redirect use recon]
expected: FAIL

9 changes: 0 additions & 9 deletions tests/wpt/metadata/url/a-element-origin-xhtml.xhtml.ini
Expand Up @@ -6,12 +6,3 @@
[Parsing origin: <https://faß.ExAmPlE/> against <about:blank>]
expected: FAIL
[Parsing origin: <http://你好你好> against <http://other.com/>]
expected: FAIL
[Parsing origin: <ftp://%e2%98%83> against <about:blank>]
expected: FAIL
[Parsing origin: <https://%e2%98%83> against <about:blank>]
expected: FAIL
9 changes: 0 additions & 9 deletions tests/wpt/metadata/url/a-element-origin.html.ini
Expand Up @@ -6,12 +6,3 @@
[Parsing origin: <https://faß.ExAmPlE/> against <about:blank>]
expected: FAIL
[Parsing origin: <http://你好你好> against <http://other.com/>]
expected: FAIL
[Parsing origin: <ftp://%e2%98%83> against <about:blank>]
expected: FAIL
[Parsing origin: <https://%e2%98%83> against <about:blank>]
expected: FAIL

0 comments on commit a97ba4f

Please sign in to comment.