diff options
author | Mathieu Agopian <mathieu@agopian.info> | 2015-12-18 17:02:41 +0100 |
---|---|---|
committer | Mathieu Agopian <mathieu@agopian.info> | 2015-12-18 17:02:41 +0100 |
commit | 11234f5370631550e925e6357881ac0dea11a120 (patch) | |
tree | e9a75b941acec5e5b3ff3f6ed8559e24fa282ab7 /components/net/fetch/request.rs | |
parent | 6764cf0ee9ce78d2d3498aec18e633e20455e050 (diff) | |
download | servo-11234f5370631550e925e6357881ac0dea11a120.tar.gz servo-11234f5370631550e925e6357881ac0dea11a120.zip |
Use Url.join instead of UrlParser.base_url(...).parse (#9002)
Diffstat (limited to 'components/net/fetch/request.rs')
-rw-r--r-- | components/net/fetch/request.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/components/net/fetch/request.rs b/components/net/fetch/request.rs index 861729f5ebf..99337e5b37c 100644 --- a/components/net/fetch/request.rs +++ b/components/net/fetch/request.rs @@ -17,7 +17,7 @@ use std::ascii::AsciiExt; use std::cell::RefCell; use std::rc::Rc; use std::str::FromStr; -use url::{Url, UrlParser}; +use url::Url; use util::task::spawn_named; /// A [request context](https://fetch.spec.whatwg.org/#concept-request-context) @@ -367,7 +367,7 @@ impl Request { _ => return Response::network_error(), }; // Step 5 - let location_url = UrlParser::new().base_url(self.url_list.last().unwrap()).parse(&*location); + let location_url = self.url_list.last().unwrap().join(&*location); // Step 6 let location_url = match location_url { Ok(ref url) if url.scheme == "data" => { return Response::network_error(); } |