changelog_bot (changelog_bot) wrote in changelog,
changelog_bot
changelog_bot
changelog

[livejournal] r18123: LJSUP-7424 Content Scanning of Posts for...

Committer: aurbanowich
LJSUP-7424 Content Scanning of Posts for Negative Terms

U   trunk/cgi-bin/LJ/Entry.pm
Modified: trunk/cgi-bin/LJ/Entry.pm
===================================================================
--- trunk/cgi-bin/LJ/Entry.pm	2011-01-27 07:57:48 UTC (rev 18122)
+++ trunk/cgi-bin/LJ/Entry.pm	2011-01-27 08:17:36 UTC (rev 18123)
@@ -1355,6 +1355,16 @@
     return $compressed;
 }
 
+sub check_for_negative_terms {
+    my $self = shift;
+    
+    my $tags = $self->prop('personifi_tags');
+    return $1 if $tags =~ /nterms:(\w+)/;
+    my $nterms = ( $self->event_raw =~ /($LJ::NEGATIVE_TERMS)/)?'no':'yes';
+    $self->set_prop(personifi_tags => ($tags?"$tags,":'') . "nterms:$nterms");
+    return $nterms;
+}
+
 package LJ;
 
 use Class::Autouse qw (

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