mirror of
https://github.com/servo/servo.git
synced 2025-06-20 07:08:59 +01:00
Provide an error message for URL parse failure
This commit is contained in:
parent
d723798298
commit
8a7cc86aa9
1 changed files with 1 additions and 1 deletions
|
@ -81,7 +81,7 @@ pub fn parse_url(str_url: &str, base_url: Option<Url>) -> Url {
|
|||
};
|
||||
|
||||
// FIXME: Need to handle errors
|
||||
url::from_str(str_url).unwrap()
|
||||
url::from_str(str_url).ok().expect("URL parsing failed")
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue