ssafronova (ssafronova) wrote in changelog,
ssafronova
ssafronova
changelog

[ljcom] r9641: LJSUP-7176: We shouldn't post REPLYs to ...

Committer: ssafronova
LJSUP-7176: We shouldn't post REPLYs to LJ when we post the tweets
U   trunk/cgi-bin/LJ/Client/Twitter.pm
Modified: trunk/cgi-bin/LJ/Client/Twitter.pm
===================================================================
--- trunk/cgi-bin/LJ/Client/Twitter.pm	2010-10-22 04:00:34 UTC (rev 9640)
+++ trunk/cgi-bin/LJ/Client/Twitter.pm	2010-10-22 08:27:59 UTC (rev 9641)
@@ -417,10 +417,12 @@
         'user' => $u,
         'http_method' => 'GET',
         'params' => { 'count'       => $LJ::TWITTER_RECENT_FEED_DEPTH,
-                      'include_rts' => 0, }, # no reply tweets
+                      'include_rts' => 1, }, # with retweets
     );
 
-    return [ map { LJ::Client::Twitter::Tweet->from_hash($_) } @$res ];
+    return [ map { LJ::Client::Twitter::Tweet->from_hash($_) } 
+             grep { not $_->{in_reply_to_status_id} and not $_->{in_reply_to_screen_name} } # without replies
+             @$res ];
 }
 
 sub get_userinfo {

Tags: ljcom, pm, ssafronova
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