madeon (madeon) wrote in changelog,
madeon
madeon
changelog

[livejournal] r22128: LJSUP-12148: JSON-RPC

Committer: sbelyaev
LJSUP-12148: JSON-RPC
U   trunk/cgi-bin/LJ/Entry/Repost.pm
Modified: trunk/cgi-bin/LJ/Entry/Repost.pm
===================================================================
--- trunk/cgi-bin/LJ/Entry/Repost.pm	2012-05-31 10:31:18 UTC (rev 22127)
+++ trunk/cgi-bin/LJ/Entry/Repost.pm	2012-05-31 11:03:20 UTC (rev 22128)
@@ -301,6 +301,7 @@
     my $reposters_info = { users => {} };
     my $users = $reposters_info->{'users'};
 
+    my $reposters_count = scalar @$repostersids;
     foreach my $reposter (@$repostersids) {
         my $u = LJ::want_user($reposter);
 
@@ -308,6 +309,7 @@
                                'url'      => $u->journal_base, };
     }   
     $reposters_info->{'last'} = $repostersids->[-1];
+    $reposters_info->{'nomore'} = 1 if $reposters_count < 25;
 
     __put_reposters_list( $journalid,
                           $jitemid,
@@ -378,9 +380,8 @@
     my $repost_itemid = __get_repostid( $entry_obj->journal, $jitemid, $u->userid );
 
     my $error;
-
     if ($repost_itemid) {
-        $error = LJ::Lang::ml('repost.already_exist');
+        $error = LJ::Lang::ml('entry.reference.repost.already_exist');
     } else {
         my $reposted_obj = __create_repost( {'u'          => $u,
                                              'entry_obj'  => $entry_obj,

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