Use maybe_serialize() where appropriate. fixes #19617.

git-svn-id: https://develop.svn.wordpress.org/trunk@20612 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin
2012-04-27 15:57:51 +00:00
parent ef79a85f78
commit 07fce717e7
3 changed files with 11 additions and 11 deletions
+2 -2
View File
@@ -1212,9 +1212,9 @@ function wp_check_browser_version() {
* 'img_src' - string - An image representing the browser
* 'img_src_ssl' - string - An image (over SSL) representing the browser
*/
$response = unserialize( wp_remote_retrieve_body( $response ) );
$response = maybe_unserialize( wp_remote_retrieve_body( $response ) );
if ( ! $response )
if ( ! is_array( $response ) )
return false;
set_site_transient( 'browser_' . $key, $response, 604800 ); // cache for 1 week