@ -85,7 +85,7 @@ else if ($_GET['_thumb']) {
// render thumbnail image if not done yet
if (!is_file($cache_file)) {
if ($fp = fopen(($orig_name = $cache_basename . '.orig.' . $ext), 'w')) {
$MESSAGE->get_part_content($part->mime_id, $fp);
$MESSAGE->get_part_body($part->mime_id, false, 0, $fp);
fclose($fp);
$image = new rcube_image($orig_name);