diff options
author | Lukas Reschke <lukas@owncloud.com> | 2015-07-02 09:16:00 +0200 |
---|---|---|
committer | Lukas Reschke <lukas@owncloud.com> | 2015-07-02 09:16:00 +0200 |
commit | d67d4f36bd189710fd21766d4006217c35abbcce (patch) | |
tree | 406a208ab5788bdb07f75ae8821f842947103081 /lib/private/app.php | |
parent | 61a60ffd4783de4e55d9a8a0c6604c857004a2e6 (diff) | |
download | nextcloud-server-d67d4f36bd189710fd21766d4006217c35abbcce.tar.gz nextcloud-server-d67d4f36bd189710fd21766d4006217c35abbcce.zip |
Delete OCS ID from DB if none is specified
If no OCS ID is specified in appinfo.xml and an app update is triggered and a OCS ID is stored in the DB we should clean the value.
Ref https://github.com/owncloud/activity/issues/320#issuecomment-117937748
Diffstat (limited to 'lib/private/app.php')
-rw-r--r-- | lib/private/app.php | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/private/app.php b/lib/private/app.php index d5e07ffdbcc..e45d9ac07ba 100644 --- a/lib/private/app.php +++ b/lib/private/app.php @@ -1174,6 +1174,8 @@ class OC_App { $appData = self::getAppInfo($appId); if (array_key_exists('ocsid', $appData)) { OC_Appconfig::setValue($appId, 'ocsid', $appData['ocsid']); + } elseif(OC_Appconfig::getValue($appId, 'ocsid', null) !== null) { + OC_Appconfig::deleteKey($appId, 'ocsid'); } foreach ($appData['remote'] as $name => $path) { OCP\CONFIG::setAppValue('core', 'remote_' . $name, $appId . '/' . $path); |