juks (juks) wrote in changelog,
juks
juks
changelog

[livejournal] r17837: LJSUP-7437 Vertical Tagging for Logged O...

Committer: iaskarov
LJSUP-7437 Vertical Tagging for Logged Out Visitors
U   trunk/cgi-bin/Apache/LiveJournal.pm
Modified: trunk/cgi-bin/Apache/LiveJournal.pm
===================================================================
--- trunk/cgi-bin/Apache/LiveJournal.pm	2010-12-01 08:56:06 UTC (rev 17836)
+++ trunk/cgi-bin/Apache/LiveJournal.pm	2010-12-01 09:37:52 UTC (rev 17837)
@@ -495,24 +495,28 @@
 
         my $remote = LJ::get_remote();
         my $u = LJ::load_user($orig_user);
-        
+
         # do redirects:
         # -- communities to the right place
         # -- uppercase usernames
         # -- users with hyphens/underscores, except users from external domains (see table 'domains')
-        if ($u && $u->is_community && $opts->{'vhost'} =~ /^(?:users||tilde)$/ ||
-            $orig_user ne lc($orig_user) ||
-            $orig_user =~ /[_-]/ && $u && $u->journal_base !~ m!^http://$host!i && $opts->{'vhost'} !~ /^other:/) {
-
-            my $newurl = $uri;
-
-            # if we came through $opts->{vhost} eq "users" path above, then
-            # the s/// below will not match and there will be a leading /,
-            # so the s/// leaves a leading slash as well so that $newurl is
-            # consistent for the concatenation before redirect
-            $newurl =~ s!^/(users/|community/|~)\Q$orig_user\E!/!;
-            $newurl = LJ::journal_base($u) . "$newurl$args_wq";
-            return redir($newurl);
+        if ($u && $u->is_community) {
+            if ($opts->{'vhost'} =~ /^(?:users||tilde)$/ ||
+                $orig_user ne lc($orig_user) ||
+                $orig_user =~ /[_-]/ && $u && $u->journal_base !~ m!^http://$host!i && $opts->{'vhost'} !~ /^other:/) {
+    
+                my $newurl = $uri;
+    
+                # if we came through $opts->{vhost} eq "users" path above, then
+                # the s/// below will not match and there will be a leading /,
+                # so the s/// leaves a leading slash as well so that $newurl is
+                # consistent for the concatenation before redirect
+                $newurl =~ s!^/(users/|community/|~)\Q$orig_user\E!/!;
+                $newurl = LJ::journal_base($u) . "$newurl$args_wq";
+                return redir($newurl);
+            } 
+            
+            LJ::run_hook('vertical_tags', $remote, $u);
         }
 
         # check if this entry or journal contains adult content

Tags: juks, livejournal, pm
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments