vadvs (vadvs) wrote in changelog,
vadvs
vadvs
changelog

[livejournal] r20444: LJSUP-10247: New RS driver

Committer: vad
LJSUP-10247: New RS driver
U   trunk/cgi-bin/LJ/RelationService.pm
Modified: trunk/cgi-bin/LJ/RelationService.pm
===================================================================
--- trunk/cgi-bin/LJ/RelationService.pm	2011-10-27 14:21:25 UTC (rev 20443)
+++ trunk/cgi-bin/LJ/RelationService.pm	2011-10-27 15:17:35 UTC (rev 20444)
@@ -8,13 +8,14 @@
     my $class = shift;
     my $user  = shift;
 
-    return 0 unless LJ::is_enable('send_test_load_to_rs2');
+    return 0 unless LJ::is_enabled('send_test_load_to_rs2');
 
     my $rate = $LJ::RELATION_SERVICE_LOAD_RATE; ## 0 .. 100
     return 0 unless $rate;
 
     ##
-    return 1 if ( (int rand(100)) > $rate );
+    my $val = int rand(100);
+    return 1 if $rate > $val;
 
     return 0;
 }

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