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

[livejournal] r21751: LJSUP-11893: allow everyone to access th...

Committer: wisest-owl
LJSUP-11893: allow everyone to access the new photo hosting galleries

U   trunk/cgi-bin/Apache/LiveJournal.pm
U   trunk/cgi-bin/LJ/User.pm
Modified: trunk/cgi-bin/Apache/LiveJournal.pm
===================================================================
--- trunk/cgi-bin/Apache/LiveJournal.pm	2012-04-19 11:58:12 UTC (rev 21750)
+++ trunk/cgi-bin/Apache/LiveJournal.pm	2012-04-19 12:59:41 UTC (rev 21751)
@@ -766,8 +766,8 @@
         }
 
         if ($opts->{'mode'} eq "ljphotoalbums" && $opts->{'user'} ne 'pics') {
-            my $burl = LJ::remote_bounce_url();
-            return remote_domsess_bounce() if LJ::remote_bounce_url();
+#            my $burl = LJ::remote_bounce_url();
+#            return remote_domsess_bounce() if LJ::remote_bounce_url();
             LJ::Request->notes("_journal" => $opts->{'user'});
 
             my $u = LJ::load_user($opts->{user});
@@ -788,17 +788,17 @@
 
             my %post_params = LJ::Request->post_params;
             ## If no remote we can try authtorize by auth_token
-            if (!$remote && !LJ::Auth->check_sessionless_auth_token (
+            if (LJ::did_post() && !LJ::Auth->check_sessionless_auth_token (
                     $LJ::DOMAIN_WEB."/pics/upload",
                     auth_token => $post_params{'form_auth'}, 
                     user => $opts->{user})
             ) {
                 LJ::Request->pnotes ('error' => 'ljphoto_members');
                 LJ::Request->pnotes ('remote' => LJ::load_user($opts->{'user'}));
+                LJ::set_remote ($u) unless $remote;
                 return LJ::Request::FORBIDDEN;
             }
 
-            LJ::set_remote ($u) unless $remote;
             $remote = LJ::get_remote();
 =head
             unless ($remote && ($remote->can_use_ljphoto() || LJ::Request->uri =~ m#^/pics/new_photo_service#)) {

Modified: trunk/cgi-bin/LJ/User.pm
===================================================================
--- trunk/cgi-bin/LJ/User.pm	2012-04-19 11:58:12 UTC (rev 21750)
+++ trunk/cgi-bin/LJ/User.pm	2012-04-19 12:59:41 UTC (rev 21751)
@@ -3861,11 +3861,15 @@
 
     return 0 if $LJ::DISABLED{'new_ljphoto'};
 
+=head
+    ## Open access to a new photohosting for all users
+    ## LJSUP-11893
     foreach my $comm_name (@LJ::LJPHOTO_ALLOW_FROM_COMMUNITIES) {
         my $comm = LJ::load_user ($comm_name);
         next unless $comm && $comm->is_visible;
         return 1 if $u->can_manage ($comm) or $comm->is_friend($u); 
     }
+=cut
 
     return 1 if $u->prop ('fotki_migration_status');
 

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