afuna: Cat under a blanket. Text: "Cats are just little people with Fur and Fangs" (Default)
afuna ([personal profile] afuna) wrote in [site community profile] changelog2009-07-25 02:21 pm

[dw-free] Add number of received comments to RSS feeds

[commit: http://hg.dwscoalition.org/dw-free/rev/c661a0bd950a]

http://bugs.dwscoalition.org/show_bug.cgi?id=1467

Add lj:reply-count tag to /data/rss feeds.

Patch from LiveJournal; prepared for Dreamwidth by [personal profile] kareila.

Files modified:
  • cgi-bin/ljfeed.pl
--------------------------------------------------------------------------------
diff -r 68d6e4987b55 -r c661a0bd950a cgi-bin/ljfeed.pl
--- a/cgi-bin/ljfeed.pl	Sat Jul 25 13:54:06 2009 +0000
+++ b/cgi-bin/ljfeed.pl	Sat Jul 25 14:20:02 2009 +0000
@@ -271,6 +271,7 @@ sub make_feed
             tags       => [ values %{$logtags->{$itemid} || {}} ],
             security   => $it->{security},
             posterid   => $it->{posterid},
+            replycount => $logprops{$itemid}->{'replycount'},
         };
         push @cleanitems, $cleanitem;
         push @entries,    $entry_obj;
@@ -355,6 +356,7 @@ sub create_view_rss
         $ret .= "  <lj:mood>" . LJ::exml($it->{mood}) . "</lj:mood>\n" if $it->{mood};
         $ret .= "  <lj:security>" . LJ::exml($it->{security}) . "</lj:security>\n" if $it->{security};
         $ret .= "  <lj:poster>" . LJ::exml($poster->user) . "</lj:poster>\n" unless LJ::u_equals($u, $poster);
+        $ret .= "  <lj:reply-count>$it->{replycount}</lj:reply-count>\n";
         $ret .= "</item>\n";
     }
 
--------------------------------------------------------------------------------

Post a comment in response:

This account has disabled anonymous posting.
If you don't have an account you can create one now.
No Subject Icon Selected
More info about formatting

If you are unable to use this captcha for any reason, please contact us by email at support@dreamwidth.org