vadvs (vadvs) wrote in changelog,
vadvs
vadvs
changelog

[ljcom] r10127: LJSUP-7770: Add some events to event str...

Committer: vsukhanov
LJSUP-7770: Add some events to event stream
U   trunk/cgi-bin/LJ/Hooks/EventsFeed.pm
Modified: trunk/cgi-bin/LJ/Hooks/EventsFeed.pm
===================================================================
--- trunk/cgi-bin/LJ/Hooks/EventsFeed.pm	2011-02-25 08:15:53 UTC (rev 10126)
+++ trunk/cgi-bin/LJ/Hooks/EventsFeed.pm	2011-02-25 08:20:15 UTC (rev 10127)
@@ -158,6 +158,7 @@
     my $entry    = $params->{entry};
     my $journal  = $params->{journal}; 
     
+    return unless LJ::is_enabled('events-feed-post-events');
     LJ::EventsFeed::NewEntry->new($journal, $entry)->fire;
 });
 
@@ -165,6 +166,8 @@
     # editpost
     my $entry = shift;
     my $u     = $entry->journal;
+
+    return unless LJ::is_enabled('events-feed-post-events');
     LJ::EventsFeed::EntryUpdated->new($u, $entry)->fire();
 });
 
@@ -173,6 +176,8 @@
     my ($jid, $jitemid, $anum) = @_;
     my $u     = LJ::load_userid($jid);
     my $entry = LJ::Entry->new($u, jitemid => $jitemid);
+
+    return unless LJ::is_enabled('events-feed-post-events');
     LJ::EventsFeed::EntryUpdated->new($u, $entry)->fire();
 });
 
@@ -181,6 +186,8 @@
     my ($userid, $jitemid, $jtalkid) = @_;
     my $u     = LJ::load_userid($userid);
     my $entry = LJ::Entry->new($u, jitemid => $jitemid);
+
+    return unless LJ::is_enabled('events-feed-comment-events');
     LJ::EventsFeed::CommentsChanged->new($u, $entry)->fire();
 });
 
@@ -190,6 +197,8 @@
 
     my $u     = LJ::load_userid($userid);
     my $entry = LJ::Entry->new($u, jitemid => $jitemid);
+
+    return unless LJ::is_enabled('events-feed-comment-events');
     LJ::EventsFeed::CommentsChanged->new($u, $entry)->fire();
 });
 
@@ -199,6 +208,8 @@
 
     my $u     = LJ::load_userid($jid);
     my $entry = LJ::Entry->new($u, jitemid => $jitemid);
+
+    return unless LJ::is_enabled('events-feed-comment-events');
     LJ::EventsFeed::CommentsChanged->new($u, $entry)->fire();
 });
 
@@ -208,6 +219,8 @@
 
     my $u     = LJ::load_userid($userid);
     my $entry = LJ::Entry->new($u, jitemid => $jitemid);
+
+    return unless LJ::is_enabled('events-feed-comment-events');
     LJ::EventsFeed::CommentsChanged->new($u, $entry)->fire();
 });
 
@@ -217,6 +230,8 @@
 
     my $u     = LJ::load_userid($userid);
     my $entry = LJ::Entry->new($u, jitemid => $jitemid);
+
+    return unless LJ::is_enabled('events-feed-comment-events');
     LJ::EventsFeed::CommentsChanged->new($u, $entry)->fire();
 });
 

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