Use wp_cache_add() in wp_mime_type_icon(). fixes #21835.
git-svn-id: http://core.svn.wordpress.org/trunk@21783 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
50b120ad64
commit
8a46609b03
|
@ -4218,7 +4218,7 @@ function wp_mime_type_icon( $mime = 0 ) {
|
||||||
if ( isset($types[$wilds[0]])) {
|
if ( isset($types[$wilds[0]])) {
|
||||||
$icon = $types[$wilds[0]];
|
$icon = $types[$wilds[0]];
|
||||||
if ( !is_numeric($mime) )
|
if ( !is_numeric($mime) )
|
||||||
wp_cache_set("mime_type_icon_$mime", $icon);
|
wp_cache_add("mime_type_icon_$mime", $icon);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue