Permalink
Browse files

Logging API: fix array to string conversion notice

log_event() used $p_msg to print the message, instead of the sanitized
$s_msg variable, so when logging DB events which are submitted as an
array with execution time, the notice gets triggered.

Regression introduced by 2d0df25

Fixes #17441
  • Loading branch information...
1 parent 4fbd340 commit c2513b1e1844bdbcd888ab41253afb7a1d59e412 @dregad dregad committed May 12, 2014
Showing with 2 additions and 2 deletions.
  1. +2 −2 core/logging_api.php
View
4 core/logging_api.php
@@ -90,7 +90,7 @@ function log_event( $p_level, $p_msg ) {
$t_now = date( config_get_global( 'complete_date_format' ) );
$t_level = $g_log_levels[$p_level];
- $t_plugin_event = '[' . $t_level . '] ' . $p_msg;
+ $t_plugin_event = '[' . $t_level . '] ' . $t_msg;
if( function_exists( 'event_signal' ) ) {
event_signal( 'EVENT_LOG', array( $t_plugin_event ) );
}
@@ -130,7 +130,7 @@ function log_event( $p_level, $p_msg ) {
if( $s_firephp === null ) {
$s_firephp = FirePHP::getInstance( true );
}
- $s_firephp->log( $p_msg, $t_php_event );
+ $s_firephp->log( $t_msg, $t_php_event );
return;
}
# if firebug is not available, fall through

0 comments on commit c2513b1

Please sign in to comment.