diff options
author | Jörn Friedrich Dreyer <jfd@butonic.de> | 2015-06-23 13:14:35 +0200 |
---|---|---|
committer | Jörn Friedrich Dreyer <jfd@butonic.de> | 2015-06-23 13:14:35 +0200 |
commit | 4b5324341c152ba14b817c13979a35e15502e39b (patch) | |
tree | b90e2e3c58b19ef6683854169734cdbe5ab5ea82 | |
parent | e72261463999da82ffa1a0952e9dd6b66153870d (diff) | |
parent | 1ba9fd3ada07c42b1151de64004702acf22382d1 (diff) | |
download | nextcloud-server-4b5324341c152ba14b817c13979a35e15502e39b.tar.gz nextcloud-server-4b5324341c152ba14b817c13979a35e15502e39b.zip |
Merge pull request #17090 from owncloud/upgrade-app-info
[upgrade] print update message before running the update code
-rw-r--r-- | core/command/upgrade.php | 3 | ||||
-rw-r--r-- | lib/private/updater.php | 1 |
2 files changed, 4 insertions, 0 deletions
diff --git a/core/command/upgrade.php b/core/command/upgrade.php index 2d6394fea85..58e98e2bbdc 100644 --- a/core/command/upgrade.php +++ b/core/command/upgrade.php @@ -158,6 +158,9 @@ class Upgrade extends Command { $updater->listen('\OC\Updater', 'appUpgradeCheck', function () use ($output) { $output->writeln('<info>Checked database schema update for apps</info>'); }); + $updater->listen('\OC\Updater', 'appUpgradeStarted', function ($app, $version) use ($output) { + $output->writeln("<info>Updating <$app> ...</info>"); + }); $updater->listen('\OC\Updater', 'appUpgrade', function ($app, $version) use ($output) { $output->writeln("<info>Updated <$app> to $version</info>"); }); diff --git a/lib/private/updater.php b/lib/private/updater.php index 7f1a493d2a0..bd9e8a65363 100644 --- a/lib/private/updater.php +++ b/lib/private/updater.php @@ -386,6 +386,7 @@ class Updater extends BasicEmitter { foreach ($stacks as $type => $stack) { foreach ($stack as $appId) { if (\OC_App::shouldUpgrade($appId)) { + $this->emit('\OC\Updater', 'appUpgradeStarted', array($appId, \OC_App::getAppVersion($appId))); \OC_App::updateApp($appId); $this->emit('\OC\Updater', 'appUpgrade', array($appId, \OC_App::getAppVersion($appId))); } |