From 26bd73ddd12125ed7725c30c1ed202b220b5ea96 Mon Sep 17 00:00:00 2001 From: Andrew Nacin Date: Tue, 11 Sep 2012 01:35:43 +0000 Subject: [PATCH] Call error_log() in wp-db without unnecessary conditionals. fixes #21103. git-svn-id: https://develop.svn.wordpress.org/trunk@21807 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/wp-db.php | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/wp-includes/wp-db.php b/wp-includes/wp-db.php index 2600d8e22a..8361e15361 100644 --- a/wp-includes/wp-db.php +++ b/wp-includes/wp-db.php @@ -1030,11 +1030,7 @@ class wpdb { else $error_str = sprintf( __( 'WordPress database error %1$s for query %2$s' ), $str, $this->last_query ); - if ( function_exists( 'error_log' ) - && ( $log_file = @ini_get( 'error_log' ) ) - && ( 'syslog' == $log_file || @is_writable( $log_file ) ) - ) - @error_log( $error_str ); + error_log( $error_str ); // Are we showing errors? if ( ! $this->show_errors )