madeon (madeon) wrote in changelog,
madeon
madeon
changelog

[livejournal] r21172: LJSUP-11241: process method for /latest ...

Committer: sbelyaev
LJSUP-11241: process method for /latest uri is changed
U   trunk/cgi-bin/Apache/LiveJournal.pm
U   trunk/cgi-bin/LJ/Entry.pm
Modified: trunk/cgi-bin/Apache/LiveJournal.pm
===================================================================
--- trunk/cgi-bin/Apache/LiveJournal.pm	2012-02-13 13:46:54 UTC (rev 21171)
+++ trunk/cgi-bin/Apache/LiveJournal.pm	2012-02-13 14:30:40 UTC (rev 21172)
@@ -888,27 +888,6 @@
             LJ::Request->notes( 'usejournal' => $user );
             return remote_domsess_bounce() if LJ::remote_bounce_url();
             return $bml_handler->($bml_file);
-
-        } elsif ($uuri =~ m#^/latest$#) { #
-            my $delayed_id = $1;
-            my $u = LJ::load_user($user);
-            if (!$u) {
-                return LJ::Request::NOT_FOUND;
-            }
-
-            if (!LJ::is_enabled("delayed_entries")) {
-                LJ::Request->pnotes ('error' => 'e404');
-                LJ::Request->pnotes ('remote' => LJ::get_remote());
-                return LJ::Request::NOT_FOUND;
-            }
-
-            my $latest_item = LJ::get_latest_item($u);
-            if (!$latest_item) {
-                return LJ::Request::NOT_FOUND;
-            }
-            my $latest_link = $u->journal_base . "/$latest_item.html";
-
-            return redir($latest_link);
         } elsif ($uuri =~ m#^/pics#) {
             $mode = "ljphotoalbums";
 

Modified: trunk/cgi-bin/LJ/Entry.pm
===================================================================
--- trunk/cgi-bin/LJ/Entry.pm	2012-02-13 13:46:54 UTC (rev 21171)
+++ trunk/cgi-bin/LJ/Entry.pm	2012-02-13 14:30:40 UTC (rev 21172)
@@ -2206,7 +2206,7 @@
 sub get_itemid_after2  { return get_itemid_near2(@_, "after");  }
 sub get_itemid_before2 { return get_itemid_near2(@_, "before"); }
 
-sub get_latest_item {
+sub get_latest_ditemid {
     my ($u, $opts) = @_;
 
     my $dbr = LJ::get_cluster_reader($u);

Tags: livejournal, madeon, pm, sbelyaev
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