Skip to:
Content

bbPress.org

Ticket #2800: 2800.01.patch

File 2800.01.patch, 1.9 KB (added by thebrandonallen, 10 years ago)
  • src/includes/core/actions.php

    diff --git src/includes/core/actions.php src/includes/core/actions.php
    index 55b5255..da77de1 100644
    add_action( 'bbp_profile_update', 'bbp_profile_update_role' ); 
    285285// Hook WordPress admin actions to bbPress profiles on save
    286286add_action( 'bbp_user_edit_after', 'bbp_user_edit_after' );
    287287
    288 // Caches
     288// New forum/topic/reply caches
    289289add_action( 'bbp_new_forum_pre_extras',  'bbp_clean_post_cache' );
    290290add_action( 'bbp_new_forum_post_extras', 'bbp_clean_post_cache' );
    291291add_action( 'bbp_new_topic_pre_extras',  'bbp_clean_post_cache' );
    add_action( 'bbp_new_topic_post_extras', 'bbp_clean_post_cache' ); 
    293293add_action( 'bbp_new_reply_pre_extras',  'bbp_clean_post_cache' );
    294294add_action( 'bbp_new_reply_post_extras', 'bbp_clean_post_cache' );
    295295
     296// Clean caches on deleted/spammed/unspammed/trashed/untrashed actions
     297add_action( 'bbp_approved_reply',   'bbp_clean_post_cache', 999 );
     298add_action( 'bbp_approved_topic',   'bbp_clean_post_cache', 999 );
     299add_action( 'bbp_deleted_reply',    'bbp_clean_post_cache', 999 );
     300add_action( 'bbp_deleted_topic',    'bbp_clean_post_cache', 999 );
     301add_action( 'bbp_spammed_reply',    'bbp_clean_post_cache', 999 );
     302add_action( 'bbp_spammed_topic',    'bbp_clean_post_cache', 999 );
     303add_action( 'bbp_trashed_reply',    'bbp_clean_post_cache', 999 );
     304add_action( 'bbp_trashed_topic',    'bbp_clean_post_cache', 999 );
     305add_action( 'bbp_unapproved_reply', 'bbp_clean_post_cache', 999 );
     306add_action( 'bbp_unapproved_topic', 'bbp_clean_post_cache', 999 );
     307add_action( 'bbp_unspammed_reply',  'bbp_clean_post_cache', 999 );
     308add_action( 'bbp_unspammed_topic',  'bbp_clean_post_cache', 999 );
     309add_action( 'bbp_untrashed_reply',  'bbp_clean_post_cache', 999 );
     310add_action( 'bbp_untrashed_topic',  'bbp_clean_post_cache', 999 );
     311
    296312/**
    297313 * bbPress needs to redirect the user around in a few different circumstances:
    298314 *