Use Url.join instead of UrlParser.base_url(...).parse (#9002)

This commit is contained in:
Mathieu Agopian 2015-12-18 17:02:41 +01:00
parent 6764cf0ee9
commit 11234f5370
41 changed files with 58 additions and 64 deletions

View file

@ -35,7 +35,6 @@ use script_task::{MainThreadScriptMsg, ScriptChan};
use std::borrow::ToOwned;
use std::cell::Cell;
use string_cache::Atom;
use url::UrlParser;
use url::form_urlencoded::serialize;
use util::str::DOMString;
@ -200,7 +199,7 @@ impl HTMLFormElement {
action = DOMString::from(base.serialize());
}
// Step 9-11
let action_components = match UrlParser::new().base_url(base).parse(&action) {
let action_components = match base.join(&action) {
Ok(url) => url,
Err(_) => return
};