Merge branch 'filoozom-patch-1'
* filoozom-patch-1: Fix divided by zero when the sync folder is empty (tot = 0) Delete cfgFile before renaming it on Windows Set the right config and home dir for each OS Update getHomeDir() to use "os/user"
This commit is contained in:
@@ -191,7 +191,10 @@ func (m *Model) ConnectionStats() map[string]ConnectionInfo {
|
||||
}
|
||||
}
|
||||
|
||||
ci.Completion = int(100 * have / tot)
|
||||
ci.Completion = 100
|
||||
if tot != 0 {
|
||||
ci.Completion = int(100 * have / tot)
|
||||
}
|
||||
|
||||
res[node] = ci
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user