[bbDev] [393] trunk/bb-includes/akismet.php: Don't hit the DB with hard akismet queries so often.

Robert Deaton false.hopes at gmail.com
Mon Sep 11 20:12:20 GMT 2006


On 9/11/06, m at wordpress.org <m at wordpress.org> wrote:
> Modified: trunk/bb-includes/akismet.php (392 => 393)
> --- trunk/bb-includes/akismet.php 2006-09-11 17:36:36 UTC (rev 392)
> +++ trunk/bb-includes/akismet.php 2006-09-11 19:28:28 UTC (rev 393)
>  $n = mt_rand(1, 5);
I think you missed delething that line ^^.
> - if ( $n % 5 )
> - $bbdb->query("OPTIMIZE TABLE $bbdb->posts");
> + if ( $n % 1000 )
> + return;
> + $bbdb->query("OPTIMIZE TABLE $bbdb->posts");
>  }
>
>  function bb_ksd_pre_post_status( $post_status ) {


-- 
--Robert Deaton


More information about the bbDev mailing list