diff options
Diffstat (limited to 'application')
-rw-r--r-- | application/api/controllers/Links.php | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/application/api/controllers/Links.php b/application/api/controllers/Links.php index 01b7e783..0a7968e3 100644 --- a/application/api/controllers/Links.php +++ b/application/api/controllers/Links.php | |||
@@ -34,15 +34,14 @@ class Links extends ApiController | |||
34 | */ | 34 | */ |
35 | public function getLinks($request, $response) | 35 | public function getLinks($request, $response) |
36 | { | 36 | { |
37 | $private = $request->getParam('private'); | 37 | $private = $request->getParam('visibility'); |
38 | $links = $this->linkDb->filterSearch( | 38 | $links = $this->linkDb->filterSearch( |
39 | [ | 39 | [ |
40 | 'searchtags' => $request->getParam('searchtags', ''), | 40 | 'searchtags' => $request->getParam('searchtags', ''), |
41 | 'searchterm' => $request->getParam('searchterm', ''), | 41 | 'searchterm' => $request->getParam('searchterm', ''), |
42 | ], | 42 | ], |
43 | false, | 43 | false, |
44 | // to updated in another PR depending on the API doc | 44 | $private |
45 | ($private === 'true' || $private === '1') ? 'private' : 'all' | ||
46 | ); | 45 | ); |
47 | 46 | ||
48 | // Return links from the {offset}th link, starting from 0. | 47 | // Return links from the {offset}th link, starting from 0. |