summaryrefslogtreecommitdiffstats
path: root/settings/ajax
diff options
context:
space:
mode:
authorLukas Reschke <lukas@statuscode.ch>2016-11-22 00:24:23 +0100
committerLukas Reschke <lukas@statuscode.ch>2016-11-22 00:24:23 +0100
commit8ee11956da956324b63849002af33c92d5ef931e (patch)
tree4ac612446aa963715ba14b070c6f6ec30c56ecb8 /settings/ajax
parent27868770135e9a4c18360661126aa4bedba6f612 (diff)
downloadnextcloud-server-8ee11956da956324b63849002af33c92d5ef931e.tar.gz
nextcloud-server-8ee11956da956324b63849002af33c92d5ef931e.zip
Use app ID instead of object
Fixes several error messages when installing an app from the appstore, including: ``` Illegal offset type in isset or empty at /media/psf/stable9/lib/private/legacy/app.php#662 Illegal offset type at /media/psf/stable9/lib/private/legacy/app.php#663 Illegal offset type at /media/psf/stable9/lib/private/legacy/app.php#661 Object of class OC_App could not be converted to string at /media/psf/stable9/lib/private/legacy/app.php#81 trim() expects parameter 1 to be string, object given at /media/psf/stable9/lib/private/legacy/app.php#628 ``` Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
Diffstat (limited to 'settings/ajax')
-rw-r--r--settings/ajax/enableapp.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/settings/ajax/enableapp.php b/settings/ajax/enableapp.php
index b378b3c918d..cf1b7f29db5 100644
--- a/settings/ajax/enableapp.php
+++ b/settings/ajax/enableapp.php
@@ -35,7 +35,7 @@ try {
$appId = (string)$_POST['appid'];
$appId = OC_App::cleanAppId($appId);
$app->enable($appId, $groups);
- OC_JSON::success(['data' => ['update_required' => \OC_App::shouldUpgrade($app)]]);
+ OC_JSON::success(['data' => ['update_required' => \OC_App::shouldUpgrade($appId)]]);
} catch (Exception $e) {
\OCP\Util::writeLog('core', $e->getMessage(), \OCP\Util::ERROR);
OC_JSON::error(array("data" => array("message" => $e->getMessage()) ));