Skip to:
Content

bbPress.org

Changeset 7206


Ignore:
Timestamp:
09/21/2021 12:39:52 AM (4 weeks ago)
Author:
johnjamesjacoby
Message:

Akismet: hook clean-up methods from r7204 into WP Cron.

This change takes stephdau's advice and schedules a daily cron on the akismet_scheduled_delete event (but only when actually adding to the Akismet post histories, to try to narrow the scope slightly).

In trunk, for 2.7.0.

See #3395.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/includes/extend/akismet.php

    r7204 r7206  
    581581            ) {
    582582
     583                // Delete old content daily
     584                if ( ! wp_next_scheduled( 'akismet_scheduled_delete' ) ) {
     585                    wp_schedule_event( time(), 'daily', 'akismet_scheduled_delete' );
     586                }
     587
    583588                // Normal result: true
    584589                if ( ! empty( $this->last_post['bbp_akismet_result'] ) && ( $this->last_post['bbp_akismet_result'] === 'true' ) ) {
Note: See TracChangeset for help on using the changeset viewer.