diff --git a/includes/batch.inc b/includes/batch.inc index 7011abf..5b78818 100644 --- a/includes/batch.inc +++ b/includes/batch.inc @@ -340,7 +340,7 @@ function _batch_process() { } $current = $total - $remaining + $finished; - $percentage = _batch_api_percentage($total, $current); + $percentage = $total ? floor($current / $total * 100) : 100; $elapsed = isset($current_set['elapsed']) ? $current_set['elapsed'] : 0; $values = array( '@remaining' => $remaining,