summaryrefslogtreecommitdiffstats
path: root/lib/private/Updater.php
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2016-11-02 21:20:23 +0100
committerGitHub <noreply@github.com>2016-11-02 21:20:23 +0100
commite74c52726877b46c471030c59ad75ea51d52fd6c (patch)
treefa0b37a15a8f930f9be02deaba07d859839b5181 /lib/private/Updater.php
parent9eede5a573d7328e74dad059b933cc25ad070bd9 (diff)
parent9b66e8f7d96cc5ca014d3f6b8031eb380d981adb (diff)
downloadnextcloud-server-e74c52726877b46c471030c59ad75ea51d52fd6c.tar.gz
nextcloud-server-e74c52726877b46c471030c59ad75ea51d52fd6c.zip
Merge pull request #1973 from nextcloud/dont-disable-shipped-apps-but-throw-instead
Throw an exception when a shipped app was not replaced before the update
Diffstat (limited to 'lib/private/Updater.php')
-rw-r--r--lib/private/Updater.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/private/Updater.php b/lib/private/Updater.php
index cd2934f7196..e7f7a944902 100644
--- a/lib/private/Updater.php
+++ b/lib/private/Updater.php
@@ -382,6 +382,9 @@ class Updater extends BasicEmitter {
// check if the app is compatible with this version of ownCloud
$info = OC_App::getAppInfo($app);
if(!OC_App::isAppCompatible($version, $info)) {
+ if (OC_App::isShipped($app)) {
+ throw new \UnexpectedValueException('The files of the app "' . $app . '" were not correctly replaced before running the update');
+ }
OC_App::disable($app);
$this->emit('\OC\Updater', 'incompatibleAppDisabled', array($app));
}