fix progressText

This commit is contained in:
Peter Cai 2020-02-20 16:07:58 +08:00
parent b4dfeb8624
commit ddb6eee9e8
No known key found for this signature in database
GPG key ID: 71F5FB4E4F3FD54F

View file

@ -65,8 +65,9 @@ isBrowser = (req) ->
# Process progress text # Process progress text
progressText = (progress) -> progressText = (progress) ->
txt = (progress * 100).toFixed(2) + "%" progress = progress * 100
if progress < 0.1 txt = progress.toFixed(2) + "%"
if progress < 10
"0" + txt "0" + txt
else else
txt txt