deprecations and other WP_DEBUG warnings
-
Here are a few others:
includes/includes/functions.php Line 58.
Change
return $result[0];
to
return $result ? $result[0] : 0;
wp-statistics.php Lines 111-140
All these add_menu()’s should have unique
'id' => 'wp-statistic_menu-001',
etc.wp-statistics.php Lines 223
For
$log_type = $_GET['type'];
$log_type = @$_GET['type'];
is good enough but
$log_type = preg_replace('/[^\w-]/', '', (string)@$_GET['type']);
is a lot safer if your code morphs in the future.The problem is people use WP_DEBUG, often with backtraces, to develop other plugins. So if yours is emitting a bunch of stuff, it gets in the way!
Viewing 10 replies - 1 through 10 (of 10 total)
Viewing 10 replies - 1 through 10 (of 10 total)
- The topic ‘deprecations and other WP_DEBUG warnings’ is closed to new replies.