[Code] update percentage (#38003) (#38047)

This commit is contained in:
Mengwei Ding 2019-06-04 16:45:02 -07:00 committed by GitHub
parent 990657c72b
commit 0d334d982e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -24,11 +24,11 @@ export const CloneStatus = (props: Props) => {
const { receivedObjects, totalObjects, indexedObjects } = cloneProgress;
if (receivedObjects === totalObjects) {
progress = `Indexing objects: ${progressRate.toFixed(
progress = `Indexing objects: ${(indexedObjects / totalObjects).toFixed(
2
)}% (${indexedObjects}/${totalObjects})`;
} else {
progress = `Receiving objects: ${progressRate.toFixed(
progress = `Receiving objects: ${(receivedObjects / totalObjects).toFixed(
2
)}% (${receivedObjects}/${totalObjects})`;
}