5164: Dont show empty progress for empty workspaces r=matklad a=matklad



bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
This commit is contained in:
bors[bot] 2020-07-01 11:05:59 +00:00 committed by GitHub
commit f372b13a85
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -168,6 +168,7 @@ impl GlobalState {
}
}
vfs::loader::Message::Progress { n_total, n_done } => {
if n_total > 0 {
let state = if n_done == 0 {
Progress::Begin
} else if n_done < n_total {
@ -185,6 +186,7 @@ impl GlobalState {
Some(Progress::percentage(n_done, n_total)),
)
}
}
},
Event::Flycheck(task) => match task {
flycheck::Message::AddDiagnostic { workspace_root, diagnostic } => {