]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
only show notice form if user is logged in, looking at own page
authorEvan Prodromou <evan@prodromou.name>
Wed, 11 Jun 2008 18:13:34 +0000 (14:13 -0400)
committerEvan Prodromou <evan@prodromou.name>
Wed, 11 Jun 2008 18:13:34 +0000 (14:13 -0400)
darcs-hash:20080611181334-84dde-e9045179a94f8c78af9d660c57a37ce6f5fc9776.gz

actions/all.php
actions/showstream.php
lib/util.php

index 83401d422d22cc667396ab726eed86c367062c1b..06d88477d5197db74e6f2e752e61b48ed1575cf8 100644 (file)
@@ -47,6 +47,12 @@ class AllAction extends StreamAction {
                common_show_header($profile->nickname . _t(" and friends"),
                                                   array($this, 'show_header'), $user);
                
+               $cur = common_current_user();
+               
+               if ($cur && $cur->id == $profile->id) {
+                       common_notice_form();
+               }
+               
                $this->views_menu();
                
                $this->show_notices($profile);
index 2130251ce170936173dd218fe6ea56ace2e8fdbc..6fed6df1282046e3edaed30d85504ab441f9064c 100644 (file)
@@ -53,6 +53,12 @@ class ShowstreamAction extends StreamAction {
                                                                                                                                   $user->nickname)));
 
                common_show_header($profile->nickname, array($this, 'show_header'), $user);
+
+               $cur = common_current_user();
+               
+               if ($cur && $cur->id == $profile->id) {
+                       common_notice_form();
+               }
                
                $this->views_menu();
                
index c6f32eeb7f123cde6e4759698843b28abce2ecfe..aa0b8f02c1af5bde54b0956c71f41bd98bdd499b 100644 (file)
@@ -170,9 +170,6 @@ function common_show_header($pagetitle, $callable=NULL, $data=NULL, $notice=NULL
                                                                'alt' => $config['site']['name'],
                                                                'id' => 'logo'));
        common_element_end('a');
-       if (common_logged_in()) {
-               common_notice_form();
-       }
        common_element_end('div');
        common_element_start('div', array('id' => 'content'));
 }