summaryrefslogtreecommitdiffstats
path: root/settings/apps.php
diff options
context:
space:
mode:
authorBart Visscher <bartv@thisnet.nl>2011-12-07 20:38:58 +0100
committerBart Visscher <bartv@thisnet.nl>2011-12-07 20:41:00 +0100
commit9ba59aee3657dd67b8c0d575f1454fe50754f1f7 (patch)
tree5db7f90aa6d51223821aa8eb97def8d4583cbfd7 /settings/apps.php
parent0342b5fc433da288f62b701bd77121d300ab30bc (diff)
downloadnextcloud-server-9ba59aee3657dd67b8c0d575f1454fe50754f1f7.tar.gz
nextcloud-server-9ba59aee3657dd67b8c0d575f1454fe50754f1f7.zip
Sort apps on name and enabled status
Diffstat (limited to 'settings/apps.php')
-rw-r--r--settings/apps.php8
1 files changed, 8 insertions, 0 deletions
diff --git a/settings/apps.php b/settings/apps.php
index 27b4c17f9e6..12a7bf77202 100644
--- a/settings/apps.php
+++ b/settings/apps.php
@@ -43,6 +43,14 @@ foreach($registeredApps as $app){
}
}
+function app_sort($a, $b){
+ if ($a['active'] != $b['active']){
+ return $b['active'] - $a['active'];
+ }
+ return strcmp($a['name'], $b['name']);
+}
+usort($apps, 'app_sort');
+
// dissabled for now
// $catagoryNames=OC_OCSClient::getCategories();
// if(is_array($catagoryNames)){