diff options
Diffstat (limited to 'core')
-rw-r--r-- | core/Command/Upgrade.php | 8 | ||||
-rw-r--r-- | core/ajax/update.php | 4 |
2 files changed, 6 insertions, 6 deletions
diff --git a/core/Command/Upgrade.php b/core/Command/Upgrade.php index acf0b503d19..69a7f1f656f 100644 --- a/core/Command/Upgrade.php +++ b/core/Command/Upgrade.php @@ -105,12 +105,12 @@ class Upgrade extends Command { $message = substr($message, 0, 57) . '...'; } $progress->setMessage($message); - if ($event[0] === 1) { + if ($event['step'] === 1) { $output->writeln(''); - $progress->start($event[1]); + $progress->start($event['max']); } - $progress->setProgress($event[0]); - if ($event[0] === $event[1]) { + $progress->setProgress($event['step']); + if ($event['step'] === $event['max']) { $progress->setMessage('Done'); $progress->finish(); $output->writeln(''); diff --git a/core/ajax/update.php b/core/ajax/update.php index 39a99323cf5..a8352cb40be 100644 --- a/core/ajax/update.php +++ b/core/ajax/update.php @@ -128,12 +128,12 @@ if (\OCP\Util::needUpgrade()) { $dispatcher = \OC::$server->getEventDispatcher(); $dispatcher->addListener('\OC\DB\Migrator::executeSql', function ($event) use ($eventSource, $l) { if ($event instanceof GenericEvent) { - $eventSource->send('success', $l->t('[%d / %d]: %s', [$event[0], $event[1], $event->getSubject()])); + $eventSource->send('success', $l->t('[%d / %d]: %s', [$event['step'], $event['max'], $event->getSubject()])); } }); $dispatcher->addListener('\OC\DB\Migrator::checkTable', function ($event) use ($eventSource, $l) { if ($event instanceof GenericEvent) { - $eventSource->send('success', $l->t('[%d / %d]: Checking table %s', [$event[0], $event[1], $event->getSubject()])); + $eventSource->send('success', $l->t('[%d / %d]: Checking table %s', [$event['step'], $event['max'], $event->getSubject()])); } }); $feedBack = new FeedBackHandler($eventSource, $l); |