Alexander Nazarov (nfokz) wrote in changelog,
Alexander Nazarov
nfokz
changelog

[livejournal] r23260: LJSUP-14095: Send a Gift link

Committer: anazarov
LJSUP-14095: Send a Gift link
U   trunk/cgi-bin/LJ/Event/Birthday.pm
Modified: trunk/cgi-bin/LJ/Event/Birthday.pm
===================================================================
--- trunk/cgi-bin/LJ/Event/Birthday.pm	2012-11-06 14:24:24 UTC (rev 23259)
+++ trunk/cgi-bin/LJ/Event/Birthday.pm	2012-11-07 09:34:04 UTC (rev 23260)
@@ -99,9 +99,8 @@
 
 sub as_html_actions {
     my ($self) = @_;
-    my $u    = shift;
 
-    my $lang = ($u && $u->prop('browselang')) || $LJ::DEFAULT_LANG;
+    my $lang = $self->bdayuser->prop('browselang') || $LJ::DEFAULT_LANG;
     my $lang_var = 'send.a.gift';
     my $giftlink = LJ::Lang::get_text($lang,$lang_var);
 
@@ -109,10 +108,10 @@
     my $ret .= "<div class='actions'>";
     $ret .= " <a href='$gifturl'>$giftlink</a>";
     unless ($LJ::DISABLED{wishlist_v2}) {
-    if (LJ::WishList->have_current($self->bdayuser)) {
-        $ret .= " View user's <a href='".$self->bdayuser->wishlist_url."'>Wishlist</a>";
+        if (LJ::WishList->have_current($self->bdayuser)) {
+            $ret .= " View user's <a href='".$self->bdayuser->wishlist_url."'>Wishlist</a>";
+        }
     }
-    }
     $ret .= "</div>";
 
     return $ret;

Tags: anazarov, livejournal, nfokz, 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