Skip to:
Content

BuddyPress.org

Ticket #7427: 7427.diff

File 7427.diff, 962 bytes (added by mahype, 8 years ago)

Actionhook bp_send_email

  • src/bp-core/bp-core-functions.php

    diff --git src/bp-core/bp-core-functions.php src/bp-core/bp-core-functions.php
    index 5dae2bc..34ca466 100644
    function bp_send_email( $email_type, $to, $args = array() ) { 
    31353135        $email->set_to( $to );
    31363136        $email->set_tokens( $args['tokens'] );
    31373137
     3138        /**
     3139         * Gives you access on the email object before sending out
     3140         *
     3141         * @since 2.8.0
     3142         *
     3143         * @param BP_Email $email                      The email object containing all email data.
     3144         * @param string $email_type                   Type of email being sent.
     3145         * @param string|array|int|WP_User $to         Either a email address, user ID, WP_User object,
     3146         *                                             or an array containg the address and name.
     3147         */
     3148        do_action_ref_array( 'bp_send_email', array( &$email, $email_type, $to ) );
     3149
    31383150        $status = $email->validate();
    31393151        if ( is_wp_error( $status ) ) {
    31403152                return $status;