mirror of
https://github.com/WordPress/WordPress.git
synced 2025-12-05 11:24:25 +01:00
Coding Standards: Check for an empty mail server URL first in wp-mail.php.
This follows a common best practice of checking for an empty value before doing a specific comparison. Follow-up to [39772]. Props dilipbheda, mukesh27. Fixes #63219. Built from https://develop.svn.wordpress.org/trunk@60122 git-svn-id: http://core.svn.wordpress.org/trunk@59458 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
a929a47c76
commit
24d315efb3
@ -16,7 +16,7 @@
|
||||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '6.9-alpha-60121';
|
||||
$wp_version = '6.9-alpha-60122';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
||||
@ -17,7 +17,7 @@ if ( ! apply_filters( 'enable_post_by_email_configuration', true ) ) {
|
||||
|
||||
$mailserver_url = get_option( 'mailserver_url' );
|
||||
|
||||
if ( 'mail.example.com' === $mailserver_url || empty( $mailserver_url ) ) {
|
||||
if ( empty( $mailserver_url ) || 'mail.example.com' === $mailserver_url ) {
|
||||
wp_die( __( 'This action has been disabled by the administrator.' ), 403 );
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user