From 7f96d9ec21a95cb85d0292b46e18235b20efbcb2 Mon Sep 17 00:00:00 2001 From: ArthurHoaro Date: Mon, 16 Jan 2017 13:57:11 +0100 Subject: Update LinkFilter to be able to filter only public links No update regarding the UI or the API for now Fixes #758 --- index.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'index.php') diff --git a/index.php b/index.php index 145ea3f6..4f07a013 100644 --- a/index.php +++ b/index.php @@ -1630,8 +1630,8 @@ function buildLinkList($PAGE,$LINKSDB, $conf, $pluginManager) } } else { // Filter links according search parameters. - $privateonly = !empty($_SESSION['privateonly']); - $linksToDisplay = $LINKSDB->filterSearch($_GET, false, $privateonly); + $visibility = ! empty($_SESSION['privateonly']) ? 'private' : 'all'; + $linksToDisplay = $LINKSDB->filterSearch($_GET, false, $visibility); } // ---- Handle paging. -- cgit v1.2.3