@@ 388-391 (lines=4) @@ | ||
385 | return $send_messages; |
|
386 | } |
|
387 | } |
|
388 | } else { |
|
389 | EE_Error::add_error( sprintf( __('Message type: %s does not exist', 'event_espresso'), $type ), __FILE__, __FUNCTION__, __LINE__ ); |
|
390 | return false; |
|
391 | } |
|
392 | // add a success message |
|
393 | if ( ! $error ) { |
|
394 | EE_Error::add_success( sprintf( __( 'The %s message has been successfully sent.', 'event_espresso'), $installed_message_types[$type]->label['singular'] ), __FILE__, __FUNCTION__, __LINE__ ); |
|
@@ 438-441 (lines=4) @@ | ||
435 | return FALSE; |
|
436 | } |
|
437 | ||
438 | } else { |
|
439 | EE_Error::add_error( sprintf( __('Message type: %s does not exist', 'event_espresso'), $type ), __FILE__, __FUNCTION__, __LINE__ ); |
|
440 | return FALSE; |
|
441 | } |
|
442 | ||
443 | } |
|
444 |
@@ 571-574 (lines=4) @@ | ||
568 | $regs_to_send = array(); |
|
569 | ||
570 | //first let's make sure we have the reg id (needed for resending!); |
|
571 | if ( ! isset( $req_data['_REG_ID'] ) ) { |
|
572 | EE_Error::add_error( __('Something went wrong because we\'re missing the registration ID', 'event_espresso'), __FILE__, __FUNCTION__, __LINE__ ); |
|
573 | return false; |
|
574 | } |
|
575 | ||
576 | //if $req_data['_REG_ID'] is an array then let's group the registrations by transaction and reg status |
|
577 | // so we can only trigger messages per group. |
@@ 586-594 (lines=9) @@ | ||
583 | $transaction_processor = EE_Registry::instance()->load_class( 'Transaction_Processor' ); |
|
584 | // set the start time for this reg step |
|
585 | if ( ! $transaction_processor->set_reg_step_initiated( $this->transaction, $reg_step->slug() ) ) { |
|
586 | if ( WP_DEBUG ) { |
|
587 | EE_Error::add_error( |
|
588 | sprintf( |
|
589 | __( 'The "%1$s" registration step was not initialized properly.', 'event_espresso' ), |
|
590 | $reg_step->name() |
|
591 | ), |
|
592 | __FILE__, __FUNCTION__, __LINE__ |
|
593 | ); |
|
594 | } |
|
595 | }; |
|
596 | } |
|
597 | } |