]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
Don't show Search in the primary nav if the user isn't logged in and the site is...
authorJeffery To <jeffery.to@gmail.com>
Tue, 11 Aug 2009 12:47:41 +0000 (20:47 +0800)
committerJeffery To <jeffery.to@gmail.com>
Tue, 11 Aug 2009 12:47:41 +0000 (20:47 +0800)
lib/action.php

index 6da9adab572df2c1c9d18bdbfad6c49eb641d3ca..1bdc4daea7cd73eef4ef56ca781eb3d802d9947b 100644 (file)
@@ -450,8 +450,10 @@ class Action extends HTMLOutputter // lawsuit
             }
             $this->menuItem(common_local_url('doc', array('title' => 'help')),
                             _('Help'), _('Help me!'), false, 'nav_help');
-            $this->menuItem(common_local_url('peoplesearch'),
-                            _('Search'), _('Search for people or text'), false, 'nav_search');
+            if ($user || !common_config('site', 'private')) {
+                $this->menuItem(common_local_url('peoplesearch'),
+                                _('Search'), _('Search for people or text'), false, 'nav_search');
+            }
             Event::handle('EndPrimaryNav', array($this));
         }
         $this->elementEnd('ul');