summaryrefslogtreecommitdiffstats
path: root/external/folderapi.php
diff options
context:
space:
mode:
Diffstat (limited to 'external/folderapi.php')
-rw-r--r--external/folderapi.php8
1 files changed, 8 insertions, 0 deletions
diff --git a/external/folderapi.php b/external/folderapi.php
index 7d490ded4..629b1cff5 100644
--- a/external/folderapi.php
+++ b/external/folderapi.php
@@ -46,8 +46,16 @@ class FolderAPI extends Controller {
public function getAll() {
+ $userId = $this->api->getUserId();
+ $result = array(
+ 'folders' => array()
+ );
+ foreach ($this->folderBusinessLayer->findAll($userId) as $folder) {
+ array_push($result['folders'], $folder->toAPI());
+ }
+ return new APIResult($result);
}