| Server IP : 127.0.1.1 / Your IP : 127.0.0.1 Web Server : Apache/2.4.52 (Ubuntu) System : Linux sealall 5.15.0-179-generic #189-Ubuntu SMP Tue May 5 18:20:56 UTC 2026 x86_64 User : devops ( 1000) PHP Version : 8.3.31 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /var/www/domains/sealall.ca/wp-content/plugins/gravitysmtp/includes/ |
Upload File : |
<?php
use Gravity_Forms\Gravity_SMTP\Handler\Handler_Service_Provider;
if ( ! function_exists( 'get_option' ) ) {
return;
}
$is_configured = \Gravity_Forms\Gravity_SMTP\Handler\Mail_Handler::is_minimally_configured();
$test_mode = \Gravity_Forms\Gravity_SMTP\Handler\Mail_Handler::is_test_mode();
if ( ! function_exists( 'wp_mail' ) && $is_configured ) {
function wp_mail( $to, $subject, $message, $headers = '', $attachments = array() ) {
/**
* Perform an action before sending an email.
*
* @param array $atts the attributes sent to wp_mail for this request
*/
do_action( 'gravitysmtp_before_email_send', compact( 'to', 'subject', 'message', 'headers', 'attachments' ) );
if ( \gsmtp_fi_third_party_needs_init() ) {
\Gravity_Forms\Gravity_SMTP\Gravity_SMTP::load_plugin();
}
return \Gravity_Forms\Gravity_SMTP\Gravity_SMTP::container()->get( \Gravity_Forms\Gravity_SMTP\Handler\Handler_Service_Provider::HANDLER )->mail( $to, $subject, $message, $headers, $attachments );
}
}
if ( ! function_exists( 'wp_mail' ) && ! $is_configured && $test_mode ) {
function wp_mail( $to, $subject, $message, $headers = '', $attachments = array() ) {
$test_mode = true;
$atts = apply_filters( 'wp_mail', compact( 'to', 'subject', 'message', 'headers', 'attachments', 'test_mode' ) );
return true;
}
}
if ( ! function_exists( 'gsmtp_fi_third_party_needs_init' ) ) {
function gsmtp_fi_third_party_needs_init() {
$container = \Gravity_Forms\Gravity_SMTP\Gravity_SMTP::container();
$handler = $container->get( Handler_Service_Provider::HANDLER );
if ( ! is_null( $handler ) ) {
return false;
}
return true;
}
}