Skip to content
Snippets Groups Projects
Commit 0782df41 authored by Bob Mottram's avatar Bob Mottram
Browse files

Fix wonky progress math

parent 5be1e27c
No related branches found
No related tags found
No related merge requests found
......@@ -881,7 +881,7 @@ function update_backup_progress_bar {
max_counter=203
progress_page="$webadmin_install_dir/backup_progress.html"
progress_counter=$(cat $backup_progress_file)
progress_percent=$((progress_counter * max_counter / 100))
progress_percent=$((progress_counter * 100 / max_counter))
if [ $progress_percent -gt 100 ]; then
progress_percent=100
fi
......@@ -910,7 +910,7 @@ function update_restore_progress_bar {
max_counter=203
progress_page="$webadmin_install_dir/restore_progress.html"
progress_counter=$(cat $restore_progress_file)
progress_percent=$((progress_counter * max_counter / 100))
progress_percent=$((progress_counter * 100 / max_counter))
if [ $progress_percent -gt 100 ]; then
progress_percent=100
fi
......@@ -939,7 +939,7 @@ function update_format_progress_bar {
max_counter=5
progress_page="$webadmin_install_dir/format_progress.html"
progress_counter=$(cat $format_progress_file)
progress_percent=$((progress_counter * max_counter / 100))
progress_percent=$((progress_counter * 100 / max_counter))
if [ $progress_percent -gt 100 ]; then
progress_percent=100
fi
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment