summaryrefslogtreecommitdiffstats
path: root/settings
diff options
context:
space:
mode:
authorRoeland Jago Douma <rullzer@users.noreply.github.com>2016-12-01 11:56:33 +0100
committerGitHub <noreply@github.com>2016-12-01 11:56:33 +0100
commit220452e9438062f8201ec27ec606f21908af12a6 (patch)
tree1bd32934461e618848f4e261b569b17c01d600ae /settings
parent4ca7f9c896508f14ea2e5d9bdce8c3d986ea05dd (diff)
parent9f27c2b3e77f24862410e83adf0dc2473bbbfa8d (diff)
downloadnextcloud-server-220452e9438062f8201ec27ec606f21908af12a6.tar.gz
nextcloud-server-220452e9438062f8201ec27ec606f21908af12a6.zip
Merge pull request #2425 from nextcloud/show-real-apps-rating
Show app store rating only for 5+ votes
Diffstat (limited to 'settings')
-rw-r--r--settings/Controller/AppSettingsController.php2
-rw-r--r--settings/templates/apps.php2
2 files changed, 3 insertions, 1 deletions
diff --git a/settings/Controller/AppSettingsController.php b/settings/Controller/AppSettingsController.php
index a665532a3b7..fe050332fc8 100644
--- a/settings/Controller/AppSettingsController.php
+++ b/settings/Controller/AppSettingsController.php
@@ -239,6 +239,8 @@ class AppSettingsController extends Controller {
'canInstall' => true,
'preview' => isset($app['screenshots'][0]['url']) ? 'https://usercontent.apps.nextcloud.com/'.base64_encode($app['screenshots'][0]['url']) : '',
'score' => $app['ratingOverall'],
+ 'ratingNumOverall' => $app['ratingNumOverall'],
+ 'ratingNumThresholdReached' => $app['ratingNumOverall'] > 5 ? true : false,
'removable' => $existsLocally,
'active' => $this->appManager->isEnabledForUser($app['id']),
'needsDownload' => !$existsLocally,
diff --git a/settings/templates/apps.php b/settings/templates/apps.php
index 3753fd67a0c..2cb8378d74e 100644
--- a/settings/templates/apps.php
+++ b/settings/templates/apps.php
@@ -53,7 +53,7 @@ script(
<div class="app-level">
{{{level}}}
</div>
- {{#if score}}
+ {{#if ratingNumThresholdReached }}
<div class="app-score">{{{score}}}</div>
{{/if}}
<div class="app-detailpage"></div>