Merge pull request #9571 from owncloud/fix_appstore_update_issue

Fix update to button issue
This commit is contained in:
Vincent Petry 2014-07-14 10:00:39 +02:00
commit e58dce2ee0
2 changed files with 3 additions and 9 deletions

View File

@ -831,13 +831,8 @@ class OC_App {
// Remove duplicates
foreach ($appList as $app) {
foreach ($remoteApps AS $key => $remote) {
if (
$app['name'] == $remote['name']
// To set duplicate detection to use OCS ID instead of string name,
// enable this code, remove the line of code above,
// and add <ocs_id>[ID]</ocs_id> to info.xml of each 3rd party app:
// OR $app['ocs_id'] == $remote['ocs_id']
) {
if ($app['name'] === $remote['name'] ||
$app['ocsid'] === $remote['id']) {
unset($remoteApps[$key]);
}
}

View File

@ -377,9 +377,8 @@ class OC_Installer{
$ocsdata=OC_OCSClient::getApplication($ocsid);
$ocsversion= (string) $ocsdata['version'];
$currentversion=OC_App::getAppVersion($app);
if($ocsversion<>$currentversion) {
if (version_compare($ocsversion, $currentversion, '>')) {
return($ocsversion);
}else{
return false;
}