Browse Source

Fix bookmarks selection of the start page

master
Julien Blanchard 5 years ago
parent
commit
a72dbd3471
  1. 9
      src/main.rs

9
src/main.rs

@ -425,7 +425,12 @@ fn follow_line(s: &mut Cursive, line: &str) {
}
fn follow_link(s: &mut Cursive, link: &str) {
let current_url = history::get_current_url().unwrap();
let next_url = current_url.join(link).expect("Not a URL");
let next_url = match history::get_current_url() {
Some(current_url) => {
current_url.join(link).expect("Not a URL")
},
None => Url::parse(link).expect("Not a URL")
};
visit_url(s, &next_url)
}

Loading…
Cancel
Save