Fix wp_get_attachment_thumb_url() tumbnail back compat. Props DD32. fixes #7242

git-svn-id: https://develop.svn.wordpress.org/trunk@8257 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2008-07-04 16:15:29 +00:00
parent 99fdb4ee9e
commit cd8d510b27
1 changed files with 1 additions and 1 deletions

View File

@ -73,7 +73,7 @@ function image_downsize($id, $size = 'medium') {
}
elseif ( $size == 'thumbnail' ) {
// fall back to the old thumbnail
if ( $thumb_file = wp_get_attachment_thumb_file() && $info = getimagesize($thumb_file) ) {
if ( ($thumb_file = wp_get_attachment_thumb_file($id)) && $info = getimagesize($thumb_file) ) {
$img_url = str_replace(basename($img_url), basename($thumb_file), $img_url);
$width = $info[0];
$height = $info[1];