sunnyman's (sunnyman) wrote in changelog,
sunnyman's
sunnyman
changelog

[ljcom] r11389: LJSUP-10937: Withdraw operation refactor...

Committer: vtroitsky
LJSUP-10937: Withdraw operation refactored.
U   trunk/cgi-bin/LJ/Widget/Shop/View/SelfPromo.pm
Modified: trunk/cgi-bin/LJ/Widget/Shop/View/SelfPromo.pm
===================================================================
--- trunk/cgi-bin/LJ/Widget/Shop/View/SelfPromo.pm	2012-02-01 12:54:48 UTC (rev 11388)
+++ trunk/cgi-bin/LJ/Widget/Shop/View/SelfPromo.pm	2012-02-01 13:25:32 UTC (rev 11389)
@@ -352,15 +352,15 @@
     # TODO (refactoring): 
 
     my $promo = $class->current_promo_info;
-    my $object = $promo->object;
 
-    unless ($object) {
+    unless ($promo) {
 
         # apparently check_current_entry cleared it out,
         # let's silently redirect them back
         return LJ::Request->redirect("$LJ::SITEROOT/shop/selfpromo.bml");
     }
 
+    my $object = $promo->object;
     unless ( $promo->object_url eq $object_url ) {
 
         # not withdrawing the correct entry, race condition?

Tags: ljcom, pm, sunnyman, vtroitsky
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