diff options
author | CHItA <mate.bartus@gmail.com> | 2015-06-05 17:43:30 +0200 |
---|---|---|
committer | Mate Bartus <mate.bartus@gmail.com> | 2015-07-08 01:28:01 +0200 |
commit | 1b81bf5b2370c045a6369705d2a11a2b35fe2281 (patch) | |
tree | e1b2f4205fa3029734fb8fb909df067eae56cfed /phpBB/install/helper | |
parent | 0dc6029bfed10fac1a09a4fd8de7d1b31407693a (diff) | |
download | forums-1b81bf5b2370c045a6369705d2a11a2b35fe2281.tar forums-1b81bf5b2370c045a6369705d2a11a2b35fe2281.tar.gz forums-1b81bf5b2370c045a6369705d2a11a2b35fe2281.tar.bz2 forums-1b81bf5b2370c045a6369705d2a11a2b35fe2281.tar.xz forums-1b81bf5b2370c045a6369705d2a11a2b35fe2281.zip |
[ticket/13740] Add better progress handling, also add log messages
PHPBB3-13740
Diffstat (limited to 'phpBB/install/helper')
-rw-r--r-- | phpBB/install/helper/config.php | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/phpBB/install/helper/config.php b/phpBB/install/helper/config.php index f39e92b622..0c04b5e950 100644 --- a/phpBB/install/helper/config.php +++ b/phpBB/install/helper/config.php @@ -232,10 +232,17 @@ class config /** * Increments the task progress + * + * @param int $increment_by The amount to increment by */ - public function increment_current_task_progress() + public function increment_current_task_progress($increment_by = 1) { - $this->progress_data['current_task_progress']++; + $this->progress_data['current_task_progress'] += $increment_by; + + if ($this->progress_data['current_task_progress'] > $this->progress_data['max_task_progress']) + { + $this->progress_data['current_task_progress'] = $this->progress_data['max_task_progress']; + } } /** |