prepare($mail); // send the e-mail return $service->send($mail); } /** * Prepares the email content for the current platform. * * @since 1.15.2 (J) - 1.5.5 (WP) */ public function prepare(VBOMailWrapper $mail) { /** * Trigger event to allow third party plugins to overwrite any property of the mail message. * * @since 1.18.2 (J) - 1.8.2 (WP) */ VBOFactory::getPlatform()->getDispatcher()->trigger('onBeforeSendMail', [$mail]); // get mail full content and replace wrapper symbols $mail_content = VBOMailParser::checkWrapperSymbols($mail->getContent()); // parse conditional text rules (properties should be set by who calls this method) VikBooking::getConditionalRulesInstance()->parseTokens($mail_content); // interpretes shortcodes contained within the full text $mail_content = do_shortcode($mail_content); // set manipulated content $mail->setContent($mail_content); // return the prepared email content return $mail_content; } }