aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private/App/AppStore
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private/App/AppStore')
-rw-r--r--lib/private/App/AppStore/Fetcher/AppFetcher.php18
1 files changed, 2 insertions, 16 deletions
diff --git a/lib/private/App/AppStore/Fetcher/AppFetcher.php b/lib/private/App/AppStore/Fetcher/AppFetcher.php
index cf5839e4994..d8c505757c8 100644
--- a/lib/private/App/AppStore/Fetcher/AppFetcher.php
+++ b/lib/private/App/AppStore/Fetcher/AppFetcher.php
@@ -93,11 +93,8 @@ class AppFetcher extends Fetcher {
$version = $versionParser->getVersion($release['rawPlatformVersionSpec']);
$ncVersion = $this->getVersion();
$min = $version->getMinimumVersion();
- $max = $version->getMaximumVersion();
$minFulfilled = $this->compareVersion->isCompatible($ncVersion, $min, '>=');
- $maxFulfilled = $max !== '' &&
- $this->compareVersion->isCompatible($ncVersion, $max, '<=');
- if ($minFulfilled && $maxFulfilled) {
+ if ($minFulfilled) {
$releases[] = $release;
}
} catch (\InvalidArgumentException $e) {
@@ -113,20 +110,15 @@ class AppFetcher extends Fetcher {
}
usort($versions, 'version_compare');
$versions = array_reverse($versions);
- $compatible = false;
if(isset($versions[0])) {
$highestVersion = $versions[0];
foreach ($releases as $release) {
if ((string)$release['version'] === (string)$highestVersion) {
- $compatible = true;
$response['data'][$dataKey]['releases'] = [$release];
break;
}
}
}
- if(!$compatible) {
- unset($response['data'][$dataKey]);
- }
}
$response['data'] = array_values($response['data']);
@@ -134,13 +126,7 @@ class AppFetcher extends Fetcher {
}
private function setEndpoint() {
- $versionArray = explode('.', $this->getVersion());
- $this->endpointUrl = sprintf(
- 'https://apps.nextcloud.com/api/v1/platform/%d.%d.%d/apps.json',
- $versionArray[0],
- $versionArray[1],
- $versionArray[2]
- );
+ $this->endpointUrl = 'https://apps.nextcloud.com/api/v1/apps.json';
}
/**