messages_delete_thread

  • do_action( 'messages_delete_thread', $thread_ids )

    Source Reference:

    • Component: BuddyPress:: bp-messages
      File: /bp-messages/bp-messages-functions.php :: Trac Source Line: 153
      		$error = 0;
      		for ( $i = 0, $count = count( $thread_ids ); $i < $count; ++$i ) {
      			if ( !$status = BP_Messages_Thread::delete( $thread_ids[$i]) )
      				$error = 1;
      		}
      
      		if ( !empty( $error ) )
      			return false;
      
      		do_action( 'messages_delete_thread', $thread_ids );
      
      		return true;
      	} else {
      		if ( !BP_Messages_Thread::delete( $thread_ids ) )
      			return false;
      
      		do_action( 'messages_delete_thread', $thread_ids );
      
      		return true;
      	}
      
    • Component: BuddyPress:: bp-messages
      File: /bp-messages/bp-messages-functions.php :: Trac Source Line: 160
      			return false;
      
      		do_action( 'messages_delete_thread', $thread_ids );
      
      		return true;
      	} else {
      		if ( !BP_Messages_Thread::delete( $thread_ids ) )
      			return false;
      
      		do_action( 'messages_delete_thread', $thread_ids );
      
      		return true;
      	}
      }
      
      function messages_check_thread_access( $thread_id, $user_id = 0 ) {
      	global $bp;
      
      	if ( empty( $user_id ) )
      		$user_id = $bp->loggedin_user->id;
      

Hook: add_action: messages_delete_thread instances (1)

  • add_action( 'messages_delete_thread',  'bp_core_clear_cache' )
    $function_to_add: bp_core_clear_cache
    $priority: 0
    $accepted_args: 0

    Source Reference:

    • Component: BuddyPress :: bp-messages
      File: /bp-messages/bp-messages-cache.php :: Trac Source Line: 11
      /*******************************************************************************
       * Caching functions handle the clearing of cached objects and pages on specific
       * actions throughout BuddyPress.
       */
      
      // Exit if accessed directly
      if ( !defined( 'ABSPATH' ) ) exit;
      
      // List actions to clear super cached pages on, if super cache is installed
      

Comments are closed.