pull/6/head
dvkt 5 years ago
parent 5ea752d822
commit 5f9b44ff15

@ -47,7 +47,7 @@ fn main() {
let mut ui = UI::new(); let mut ui = UI::new();
if let Err(e) = ui.open(url) { if let Err(e) = ui.open(url) {
ui::error(&e.to_string()); eprintln!("{}", e);
exit(1); exit(1);
} }
ui.run(); ui.run();

@ -150,7 +150,7 @@ impl UI {
}); });
// main thread - check for updates in a loop // main thread - check for updates in a loop
let mut res = String::new(); let res;
loop { loop {
if let Ok(body) = rx.try_recv() { if let Ok(body) = rx.try_recv() {
spintx.send(true); spintx.send(true);
@ -161,7 +161,7 @@ impl UI {
return Err(io_error("Connection error".into())); return Err(io_error("Connection error".into()));
} }
} }
res.push_str(&body); res = body;
break; break;
} }
} }

Loading…
Cancel
Save