wisest owl (wisest_owl) wrote in changelog,
wisest owl
wisest_owl
changelog

[livejournal] r21938: LJSUP-11988: implement suspending indivi...

Committer: wisest-owl
LJSUP-11988: implement suspending individual images in the new photo hosting

U   trunk/cgi-bin/LJ/Console/Command/Suspend.pm
U   trunk/cgi-bin/LJ/Console/Command/Unsuspend.pm
Modified: trunk/cgi-bin/LJ/Console/Command/Suspend.pm
===================================================================
--- trunk/cgi-bin/LJ/Console/Command/Suspend.pm	2012-05-12 12:23:39 UTC (rev 21937)
+++ trunk/cgi-bin/LJ/Console/Command/Suspend.pm	2012-05-12 12:27:20 UTC (rev 21938)
@@ -34,6 +34,7 @@
     if ($photo) {
         ## we've got a photo url
         ## suspend and return
+        $photo->set_prop ('suspended', 1);
         $photo->set_prop ('suspend_reason', $reason);
         my $journal = $photo->owner;
         LJ::statushistory_add($journal, $remote, "suspend", "photo: $user / $reason");
@@ -45,6 +46,7 @@
     if ($album) {
         ## we've got an album url
         ## suspend and return
+        $album->set_prop ('suspended', 1);
         $album->set_prop ('suspend_reason', $reason);
         my @photos = $album->photos;
         if ($LJ::PICS_IMAGES_USE_CDN) {

Modified: trunk/cgi-bin/LJ/Console/Command/Unsuspend.pm
===================================================================
--- trunk/cgi-bin/LJ/Console/Command/Unsuspend.pm	2012-05-12 12:23:39 UTC (rev 21937)
+++ trunk/cgi-bin/LJ/Console/Command/Unsuspend.pm	2012-05-12 12:27:20 UTC (rev 21938)
@@ -42,7 +42,7 @@
     if ($photo) {
         ## we've got a photo url
         ## suspend and return
-        $photo->set_prop ('suspend_reason', 0);
+        $photo->set_prop ('suspended', 0);
         my $journal = $photo->owner;
         LJ::statushistory_add($journal, $remote, "unsuspend", "photo: $user / $reason");
         $photo->delete_from_cdn () if $LJ::PICS_IMAGES_USE_CDN;
@@ -53,7 +53,7 @@
     if ($album) {
         ## we've got an album url
         ## suspend and return
-        $album->set_prop ('suspend_reason', 0);
+        $album->set_prop ('suspended', 0);
         my @photos = $album->photos;
         if ($LJ::PICS_IMAGES_USE_CDN) {
             $_->delete_from_cdn () foreach @photos;

Tags: livejournal, pm, wisest-owl
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