]> git.immae.eu Git - github/shaarli/Shaarli.git/blobdiff - index.php
Merge pull request #604 from ArthurHoaro/no-delicious
[github/shaarli/Shaarli.git] / index.php
index 0bda46f9b6fe0046148ef519b353956aced741ba..55b12adc9384859c472b4135292ff12beec50415 100644 (file)
--- a/index.php
+++ b/index.php
@@ -1159,6 +1159,7 @@ function renderPage($conf, $pluginManager)
             $PAGE->assign('timezone_form', $timezone_form);
             $PAGE->assign('timezone_js',$timezone_js);
             $PAGE->assign('private_links_default', $conf->get('privacy.default_private_links', false));
+            $PAGE->assign('session_protection_disabled', $conf->get('security.session_protection_disabled', false));
             $PAGE->assign('enable_rss_permalinks', $conf->get('feed.rss_permalinks', false));
             $PAGE->assign('enable_update_check', $conf->get('updates.check_updates', true));
             $PAGE->assign('hide_public_links', $conf->get('privacy.hide_public_links', false));
@@ -1675,10 +1676,7 @@ function buildLinkList($PAGE,$LINKSDB, $conf, $pluginManager)
         $keys[] = $key;
     }
 
-    // If there is only a single link, we change on-the-fly the title of the page.
-    if (count($linksToDisplay) == 1) {
-        $conf->set('pagetitle', $linksToDisplay[$keys[0]]['title'] .' - '. $conf->get('general.title'));
-    }
+
 
     // Select articles according to paging.
     $pagecount = ceil(count($keys) / $_SESSION['LINKS_PER_PAGE']);
@@ -1740,9 +1738,10 @@ function buildLinkList($PAGE,$LINKSDB, $conf, $pluginManager)
         'links' => $linkDisp,
         'tags' => $LINKSDB->allTags(),
     );
-    // FIXME! temporary fix - see #399.
-    if ($conf->exists('pagetitle') && count($linkDisp) == 1) {
-        $data['pagetitle'] = $conf->get('pagetitle');
+
+    // If there is only a single link, we change on-the-fly the title of the page.
+    if (count($linksToDisplay) == 1) {
+        $data['pagetitle'] = $linksToDisplay[$keys[0]]['title'] .' - '. $conf->get('general.title');
     }
 
     $pluginManager->executeHooks('render_linklist', $data, array('loggedin' => isLoggedIn()));