Make user option name sanitization consistent. Props filosofo. fixes #5901
git-svn-id: https://develop.svn.wordpress.org/trunk@6902 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
5a97e68cd1
commit
ca7112e8d3
@ -82,6 +82,7 @@ function user_pass_ok($user_login,$user_pass) {
|
||||
function get_user_option( $option, $user = 0 ) {
|
||||
global $wpdb;
|
||||
|
||||
$option = preg_replace('|[^a-z0-9_]|i', '', $option);
|
||||
if ( empty($user) )
|
||||
$user = wp_get_current_user();
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user