Fix storage of illegal_names. Add an upgrade routine to fix bad values.

props SergeyBiryukov.
see #23418.
for trunk.



git-svn-id: https://develop.svn.wordpress.org/trunk@24448 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin
2013-06-19 22:06:42 +00:00
parent fb97e258f9
commit ea92deb1bb
3 changed files with 12 additions and 2 deletions

View File

@@ -2901,7 +2901,7 @@ function sanitize_option($option, $value) {
case 'illegal_names':
if ( ! is_array( $value ) )
$value = explode( "\n", $value );
$value = explode( ' ', $value );
$value = array_values( array_filter( array_map( 'trim', $value ) ) );